《Oracle PL/SQL開發指南》學習筆記30——原始碼除錯——錯誤管理(第四部分,utl_call_stack包中的函式)
阿新 • • 發佈:2018-12-07
utl_call_stack包中的函式整理如下:
Package Function | Description |
backtrace_depth | Returns the number of backtrace items in the backtrace. It returns a PLS_INTEGER of 1 or greater, and returns a 0 in the absence of an exception. |
backtrace_line |
Returns the line number of the backtrace unit at the specified backtrace depth. It takes a single input parameter, which is the result from the backtrace_depth function. It returns the line number where the error occurred at that particular depth of execution. |
backtrace_unit | Returns the name of the unit at the specified backtrace depth. It takes a single input parameter, which is the result from the backtrace_depth function. It returns a module name or a null value for an anonymous block. |
current_edition |
Returns the current edition name of the unit of the subprogram at the specified dynamic depth. It takes a single input parameter, which is the result from the backtrace_depth function. It returns the edition name of the program where the database employs edition-based redefinition. |
concatenate_subprogram | Returns a concatenated form of a unit-qualified name. Takes the qualified name as an input parameter and returns the fully qualified program name. |
dynamic_depth | Returns the number of subprograms on the call stack. |
error_depth | Returns the number of errors on the error stack. |
error_msg | Returns the error message of the error at the specified error depth. |
error_number | Returns the error number of the error at the specified error depth. It takes a single input parameter, which is the result from the backtrace_depth function. |
lexical_depth | Returns the lexical nesting level of the subprogram at the specified dynamic depth. It takes a single input parameter, which is the result from the backtrace_depth function. |
owner | Returns the owner name of the unit of the subprogram at the specified dynamic depth. It takes a single input parameter, which is the result from the backtrace_depth function. |
unit_line | Returns the line number of the unit of the subprogram at the specified dynamic depth. It takes a single input parameter, which is the result from the backtrace_depth function. |
subprogram | Returns the unit-qualified name of the subprogram at the specified dynamic depth. It takes a single input parameter, which is the result from the backtrace_depth function. |