tags:

views:

47

answers:

1

I see that in PL/SQL it is possible to set the session state of a particular variable for the remainder of the session's lifetime. For instance:

ALTER SESSION SET CURRENT_SCHEMA=<schema>

How do I query for the current state of this schema so I can revert back to it after performing some other statements?

+1  A: 
SELECT SYS_CONTEXT( 'USERENV', 'CURRENT_SCHEMA' ) FROM dual;
Justin Cave
Thanks - that's all I needed!
j0rd4n