RE: SYS_CONTEXT -- How to determine the current user?

From: Powell, Mark D <>
Date: Fri, 22 Feb 2008 14:46:35 -0500
Message-ID: <>

 Rumpi, in a multi-tier environment usually on one username is used to connect to Oracle and all the connections come from a limited number of application servers so the value of v$session.username and osuser are basically constants. To know who the real user is the application has to pass this information in to the database usually using the dbms_application_info package provided for this purpose.

  • Mark D Powell -- Phone (313) 592-5148

-----Original Message-----

[] On Behalf Of Rumpi Gravenstein Sent: Friday, February 22, 2008 1:41 PM
Subject: SYS_CONTEXT -- How to determine the current user?


I've looked around and am wondering how and who sets the SYS_CONTEXT('USERENV', ??????) namespace variables. My issue is that I'm working in a three tier .net environment, and the value I would like to see isn't set. Is this something the web server has to be configured to supply, or does the application developer have to code this? Specifically, I'm looking for the user for whom the current sql is being run. I've looked at values like

PROXY_USERID All of this is happening in an active directory windows environment with Oracle 10.2. It's possible that I'm just not looking at the right value, any suggestions in that area are welcome.


Rumpi Gravenstein

-- Received on Fri Feb 22 2008 - 13:46:35 CST

Original text of this message