Skip to content

Commit 463f5d2

Browse files
committed
SQL to create a procedure to show events in the database
Create the procedure so you don't need the SQL script to call
1 parent 9e7523d commit 463f5d2

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed

Diff for: proc_show_events.sql

+24
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
REM Script Name : proc_show_events.sql
2+
REM Author : Craig Richards
3+
REM Created : 11 April 2013
4+
REM Last Modified :
5+
REM Version : 1.0
6+
REM
7+
REM Modifications :
8+
REM
9+
REM Description : Create a procedure you can call to show what events are set in the database, this is for sessions mainly, but if they are set in the database they will exist in all sessions
10+
11+
CREATE OR REPLACE PROCEDURE cr_show_events
12+
AS
13+
event_level NUMBER;
14+
BEGIN
15+
FOR i IN 10000..10999 LOOP
16+
sys.dbms_system.read_ev(i,event_level);
17+
IF (event_level > 0) THEN
18+
DBMS_OUTPUT.ENABLE(1000000);
19+
DBMS_OUTPUT.PUT_LINE('Event '||to_char(i)||' set at level '||
20+
TO_CHAR(event_level));
21+
END IF;
22+
END LOOP;
23+
END;
24+
/

0 commit comments

Comments
 (0)