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: What's my session's pid?

Re: What's my session's pid?

From: Mladen Gogala <gogala_at_sbcglobal.net>
Date: Wed, 17 Aug 2005 01:23:20 GMT
Message-Id: <pan.2005.08.17.01.23.20.84170@sbcglobal.net>


On Tue, 16 Aug 2005 13:30:48 -0700, Bart the bear wrote:

> select spid from v$process
> where addr in (
> select paddr from v$session
> where sid=dbms_support.mysid)

For this to work, package DBMS_SUPPORT needs to be installed. This package is not installed by default and even if it is, an ordinary user normally doesn't have execute privilege. Better version is here:

select spid from v$process
where addr in (

      select paddr from v$session 
      where audsid=sys_context('USERENV','SESSIONID'));

-- 
http://www.mgogala.com
Received on Tue Aug 16 2005 - 20:23:20 CDT

Original text of this message

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