Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: whoami

Re: whoami

From: John Strange <jstrange_at_imtn.dsccc.com>
Date: 22 May 1998 11:51:56 GMT
Message-ID: <6k3oss$2ak$1@relay1.dsccc.com>


Here is one which gets processes, terminal, site id, and user.

        BEGIN
          SELECT PROC.PID

,PROC.SPID
,PROC.TERMINAL
,SES.OSUSER
,SES.PROCESS
INTO l_pid
,l_spid
,l_terminal
,l_username
,l_sid
FROM V_$PROCESS PROC, V_$SESSION SES WHERE SES.AUDSID = TO_NUMBER(USERENV('SESSIONID')) AND SES.TERMINAL = USERENV('TERMINAL') AND PROC.ADDR = SES.PADDR ;

Dbas would not allow direct access to V_$ tables, They did create views for us to use.

Umar FArooq (umar.farooq_at_cressoft.com.pk) wrote: : is there a command (or column of a view/table) in oracle equivalent to : the 'whoami' unix command

: THx.

--
While DSC may claim ownership of all my ideas (on or off the job), DSC does not claim any responsibility for them. Warranty expired when you opened this article and I will not be responsible for its contents or use. Received on Fri May 22 1998 - 06:51:56 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US