Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Environment within PL/SQL (like environment variables)
Jeremy wrote:
> Would like to record (this is a web app) the IP address of the caller
> plus various other bits of information. I was just wondering if there
> are any system variables for example containing the name of the
> currently executing package.procedure ?
In a mod_plsql web app you can access the CGI environment using the function owa_util.get_cgi_env.
The CGI environment contains a lot of useful information. Procedure owa_util.print_cgi_env print out on the browser a list of CGI environment variables available together with their current content.
For example you can get the name of the current package.procedure that way:
path_info := substr(owa_util.get_cgi_env('PATH_INFO'),2);
HTH. Kind regards,
-- Cris Carampa (spamto:cris119_at_operamail.com) All foreign wars I do proclaim Live on blood and a mother's painReceived on Thu Jun 29 2006 - 09:23:01 CDT