Re: Getting the name of currently executing sql script in sql*plus
Date: Fri, 4 Dec 2009 23:09:11 -0500
Message-ID: <8311a5b60912042009v51d9fec2s73caad69e7349f20_at_mail.gmail.com>
You could use DBMS_APPLICATION_INFO<http://download.oracle.com/docs/cd/E11882_01/appdev.112/e10577/d_appinf.htm>to do that, something like this:
BEGIN
dbms_application_info.set_module
( module_name => 'running scripts',
action_name => 'script 1' );
END;
/
*_at_script 1*
BEGIN
dbms_application_info.set_action( action_name => 'script 2' );
END;
/
*_at_script 2*
BEGIN
dbms_application_info.set_action( action_name => 'script 3' );
END;
/
*_at_script 3*
etc...
chet
On Fri, Dec 4, 2009 at 10:39 PM, Srinivas Chintamani < srinivas.chintamani_at_gmail.com> wrote:
> Hi Listers,
> Is there any way to get the name of the current script being executed by
> sql*plus?
>
> For example..
> I have the following levels of scripts ...
>
> 1. Driver_Script.sql calls
> 2.....one.sql and
> 3.....two.sql
> 4.....three.sql which calls
> 5............four.sql and
> 6............five.sql.
>
> What I want to be able to do is within each one of those scripts, "Get" the
> name of the script being executed. Is it possible to do this?
>
> --
> Regards,
> Srinivas Chintamani
>
-- http://www.freelists.org/webpage/oracle-lReceived on Fri Dec 04 2009 - 22:09:11 CST