Search Results trace_all_exceptions




Overview

SYS.DBMS_TRACE is a server-side PL/SQL package that provides the runtime interface for starting, stopping, and controlling the PL/SQL trace facility (the PL/SQL Virtual Machine trace, historically associated with the MTRACE / LTRACE debugging infrastructure). It does not perform business logic of its own; rather, it is a diagnostics utility used throughout Oracle E-Business Suite 12.1.1 and 12.2.2 to capture execution-level detail from PL/SQL program units when standard SQL trace (event 10046) is insufficient.

In the EBS context, DBMS_TRACE is the mechanism by which developers and DBAs obtain call/return sequences, exception paths, per-line execution information, and PL/SQL-level SQL statement activity from forms-based server code, concurrent program PL/SQL, and stored APIs. Because tracing is controlled by integer flag constants defined in the package specification, the facility can be scoped narrowly — for example, tracing only calls made from units compiled in debug mode — which limits the volume of collected data and the associated overhead on a production or test instance.

Key Procedures and Functions

The documented interface comprises ten members:

Tables Accessed

The ETRM metadata records no tables referenced through APPS synonyms, and the package is not referenced by other packages. The trace output itself is written to internal fixed tables (the SYS.PLSQL_TRACE family, historically viewed through SYS.PLSQL_TRACE_RUNS and related views), which are session-scoped diagnostics rather than application data. Consequently, invoking DBMS_TRACE does not read or modify EBS business tables.

Usage Notes

DBMS_TRACE is typically invoked from SQL*Plus or another DBA session by first enabling the feature at instance level, then calling SET_PLSQL_TRACE in the target session, executing the EBS transaction under investigation (a form, an API call, or a concurrent program), and finally calling CLEAR_PLSQL_TRACE. Querying results requires the run number returned by GET_PLSQL_TRACE_RUNNUMBER. It is a diagnostic-only utility: it should not be embedded in production business logic, and a corresponding DBMS_TRACE call should only be added to custom code when PL/SQL-level tracing is deliberately required, since the alternative for SQL-level diagnosis remains the standard SQL trace and TKPROF workflow. In all cases, tracing must be removed or disabled once the investigation closes to avoid unnecessary overhead.