Create view on v$session : session « System Tables Views « Oracle PL / SQL






Create view on v$session

 
SQL>
SQL> CREATE VIEW session_log AS
  2  SELECT *
  3  FROM   v$session
  4  WHERE  username = USERNAME;


SQL>
SQL> select * from session_log;


SQL>
SQL>
SQL> SELECT username, sid, serial#, module, action
  2  FROM   session_log;


SQL>
SQL>
SQL> drop view session_log;

 








Related examples in the same category

1.Query v$session table
2.Query v$lock, v$session table