index

Package cout_err



Program units
report_and_stop   Reports the error and RAISES an exception to halt program execution
report_and_go   Reports the error and continues program execution
logto   Allows the specification of the log destination
logging_to   Returns the current log destination.
about   Return an identification string to link to the source control system.

Types
g_t_substitution_list   Specifies the substitution values that could be passed into any generated error message

Variables
c_empty_substitution_list  

Constants
g_header  
g_revision  
c_table   Specifies logging to be table-based (ERROR_LOGS), this the default log method.
c_file   Specifies logging to be file-based.
c_screen   Specifies logging to be screen-based.


g_header

g_header   CONSTANT VARCHAR2(160) := '$Header: /Isle Of Grain/Database/PLSQL/cout_err.pck 3     1/04/05 16:13 Hardya $';

g_revision

g_revision CONSTANT VARCHAR2(160) := '$Revision: 3 $';

c_table

c_table CONSTANT PLS_INTEGER := 1;

Specifies logging to be table-based (ERROR_LOGS), this the default log method.


c_file

c_file CONSTANT PLS_INTEGER := 2;

Specifies logging to be file-based.


c_screen

c_screen CONSTANT PLS_INTEGER := 3;

Specifies logging to be screen-based.


g_t_substitution_list

TYPE g_t_substitution_list IS TABLE OF VARCHAR2(80) INDEX BY BINARY_INTEGER;

Specifies the substitution values that could be passed into any generated error message


c_empty_substitution_list

c_empty_substitution_list g_t_substitution_list;

report_and_stop

PROCEDURE report_and_stop(p_exception_number  IN INTEGER := SQLCODE
                         ,p_exception_message IN VARCHAR2 := NULL
                         ,p_substitution_list IN g_t_substitution_list := c_empty_substitution_list
                         ,p_helper_call_level IN NUMBER := 0
                         ,p_error_group       IN VARCHAR2 := 'APPLICATION'
                         ,p_severity          IN VARCHAR2 := 'E'
                         ,p_source            IN VARCHAR2 := NULL)

Reports the error and RAISES an exception to halt program execution

Parameters
p_exception_number   The exception to be raised, defaults to SQLCODE
p_exception_message   The message to be logged, defaults to the matching message from EXCEPTION_MESSAGES
p_helper_call   If TRUE, indicates that this report is being produced through a helper function
p_error_group   The error group that this error should be reported as a part of


report_and_go

PROCEDURE report_and_go(p_exception_number  IN INTEGER := SQLCODE
                       ,p_exception_message IN VARCHAR2 := NULL
                       ,p_substitution_list IN g_t_substitution_list := c_empty_substitution_list
                       ,p_helper_call_level IN NUMBER := 0
                       ,p_error_group       IN VARCHAR2 := 'APPLICATION'
                       ,p_severity          IN VARCHAR2 := 'E'
                       ,p_source            IN VARCHAR2 := NULL)

Reports the error and continues program execution

Parameters
p_exception_number   The exception to be raised, defaults to SQLCODE
p_exception_message   The message to be logged, defaults to the matching message from EXCEPTION_MESSAGES
p_helper_call   If TRUE, indicates that this report is being produced through a helper function
p_error_group   The error group that this error should be reported as a part of


logto

PROCEDURE logto(p_target IN PLS_INTEGER
               ,p_dir    IN VARCHAR2 := NULL
               ,p_file   IN VARCHAR2 := NULL)

Allows the specification of the log destination

Parameters
p_target   The destination (as defined by the constants c_table, c_file and c_screen
p_dir   If file has been chosen, allows the log directory to be specified
p_file   If file has been chosen, allows the log filename to be specified


logging_to

FUNCTION logging_to RETURN PLS_INTEGER

Returns the current log destination.

Returns
Returns a value matching c_table, c_file or c_screen


about

FUNCTION about RETURN VARCHAR2

Return an identification string to link to the source control system.