Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Getting own session id
In article <959932900.12529.0.pluto.d4ee154e_at_news.demon.nl>,
"Sybrand Bakker" <postbus_at_sybrandb.demon.nl> wrote:
> select sid, serial#
> from v$session
> where audsid = userenv('sessionid')
>
> (and audsid is a sequence too!)
>
> Hth,
>
> Sybrand Bakker, Oracle DBA
>
> <arivlin_at_my-deja.com> schreef in berichtnieuws
> 8h72ac$p5v$1_at_nnrp1.deja.com...
> > I could not , so I created my own sequence to identify sessions.
> > If you find out how to do that, please copy me on it.
> > Thank you.
> > Alex
> >
> >
> > In article <8gmve6$97i$1_at_news.xmission.com>,
> > "Hello" <hello_at_hello.world> wrote:
> > > Is there any way to find out the session id or serial# for the
current
> > > session, v$session is fine but I don't know of a way to identify
the
current
> > > session itself, most of the times it is a lucky guess.
> > >
> > > Thanks
> > >
> > >
> >
> >
> > Sent via Deja.com http://www.deja.com/
> > Before you buy.
>
>
An easier way: select * from v$mystat
-Bass Chorng
Sent via Deja.com http://www.deja.com/
Before you buy.
Received on Fri Jun 02 2000 - 00:00:00 CDT