Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: How to identify spid of caller
Bill Wine wrote:
>
> If I am logged into the database more than once, with the same
> username, terminal, program, and I do this query:
>
> select * from v$session where username = user
>
> how would I find which row corresponds to the current, or calling
> process? This would be from a PL/SQL procedure.
>
> Thanks for your help.
>
> Bill
select * from v$session where audsid = userenv('sessionid');
will do the trick!
John Hough Received on Fri Feb 07 1997 - 00:00:00 CST