-
identify current session
how can i get sid, serial# of my current session
from v$session (or any related view) ?
thank you!
-Raja
-
-
-
Originally posted by davey23uk
and the sys_context
If you mean the provided namspace USERENV, then I'm affraid there is no such parameter in there that would return SID or serial# for the session. Note that parameter SESSIONID in that namespace returns auditing session identifier, which is something totaly different from SID in V$SESSION and simmilar views.
As mentioned before, V$MYSTAT is the correct view to obtain your current SID.
SELECT sid FROM v$mystat WHERE ROWNUM = 1;
Jurij Modic
ASCII a stupid question, get a stupid ANSI
24 hours in a day .... 24 beer in a case .... coincidence?
-
better use rownum < 2, rownum = 1 doesnt work very well with cursor_sharing = FORCE or SIMILAR
-
thank you everybody!
-Raja
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|