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

Home -> Community -> Mailing Lists -> Oracle-L -> Re: find the system process for an oracle session

Re: find the system process for an oracle session

From: Stephane Faroult <sfaroult_at_oriole.com>
Date: Fri, 22 Nov 2002 08:14:13 -0800
Message-ID: <F001.0050963E.20021122081413@fatcity.com>


Ruth Gramolini wrote:
>
> Good morning,
>
> Can anyone send my the sql to find the system process being used by an
> oracle session. I know this has been out here before, but I can't find it
> in my saved stuff.
>
> Thanks in advance,
> Ruth
>

Ruth,

  It depends on whether you want the client process (eg the sqlplus process) or the shadow process identifier.

You find the first one as column PROCESS in V$SESSION, and identify the row either by the SID (session identifier) or by saying AUDSID = SYS_CONTEXT('USERENV', 'SESSIONID') to identify the currently running session.
The second one is column SPID in V$PROCESS, and you can join V$SESSION to V$PROCESS by saying V$SESSION.PADDR = V$PROCESS.ADDR.

-- 
HTH,

Stephane Faroult
Oriole Software
-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.com
-- 
Author: Stephane Faroult
  INET: sfaroult_at_oriole.com

Fat City Network Services    -- 858-538-5051 http://www.fatcity.com
San Diego, California        -- Mailing list and web hosting services
---------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).
Received on Fri Nov 22 2002 - 10:14:13 CST

Original text of this message

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