oracle show running procedures code example

Example: oracle show running procedures

SELECT 'CALLED PLSQL' AS STATUT,
       VS.USERNAME,
       VS.OSUSER,
       VS.PROGRAM,
       VS.MODULE,
       VS.ACTION,
       VS.SQL_EXEC_START,
       D_O.OBJECT_NAME,
       D_O.OBJECT_TYPE
FROM DBA_OBJECTS D_O
         INNER JOIN V$SESSION VS ON D_O.OBJECT_ID = VS.PLSQL_ENTRY_OBJECT_ID
UNION ALL
SELECT 'CURRENT PLSQL' AS STATUT,
       VS.USERNAME,
       VS.OSUSER,
       VS.PROGRAM,
       VS.MODULE,
       VS.ACTION,
       VS.SQL_EXEC_START,
       D_O.OBJECT_NAME,
       D_O.OBJECT_TYPE
FROM DBA_OBJECTS D_O
         INNER JOIN V$SESSION VS ON D_O.OBJECT_ID = VS.PLSQL_OBJECT_ID;

Tags:

Misc Example