DBMS_MONITOR.SESSION_TRACE_DISABLE Procedure

This procedure, which was introduced in Oracle 10.1, disables event 10046 trace in the specified session

Argument Name Type In/Out Default?
SESSION_ID BINARY_INTEGER IN DEFAULT
SERIAL_NUM BINARY_INTEGER IN DEFAULT

If the SESSION_ID is NULL and SERIAL_NUM is NULL then trace is disabled in the current session

If the SESSION_ID is NOT NULL and SERIAL_NUM is NULL specified then trace is disabled in a session with the specified SESSION_ID

If the SESSION_ID is NOT NULL and SERIAL_NUM is NOT NULL then trace is disabled in the specified SESSION_ID/SID

If SESSION_ID is NULL and SERIAL_NUM is NOT NULL an error is returned

For example to disable event 10046 trace in the current session use:

EXECUTE dbms_monitor.session_trace_disable

This is equivalent to:

ALTER SESSION SET EVENTS '10046 trace name context off';

To disable event 10046 trace in a session with SID 9, serial number 29 use:

EXECUTE dbms_monitor.session_trace_disable (9, 29);

This is equivalent to:

EXECUTE dbms_system.set_ev (9, 29, 10046, 0, '');