The USE statement specifies Declarative procedures to handle input/output errors and database exception conditions. It can also specify procedures to be executed before the program processes a specific report group. These procedures supplement the standard procedures in the COBOL Run-Time System and OpenVMS RMS.
1 – 1format AFTER EXCEPTION
The USE statement specifies Declarative procedures to handle input/output errors and database exception conditions. It can also specify procedures to be executed before the program processes a specific report group. These procedures supplement the standard procedures in the COBOL Run-Time System and OpenVMS RMS. Format 1 - { {file-name} ...} { INPUT } USE [GLOBAL] AFTER STANDARD {EXCEPTION }PROCEDURE ON{ OUTPUT }. {ERROR } { I-O } { EXTEND }
1.1 – file-name
is the name of a file connector described in a file description entry in a Data Division. It cannot refer to a sort or merge file.
2 – 2format BEFORE REPORTING
The USE statement specifies Declarative procedures to handle input/output errors and database exception conditions. It can also specify procedures to be executed before the program processes a specific report group. These procedures supplement the standard procedures in the COBOL Run-Time System and OpenVMS RMS. Format 2 - USE [GLOBAL] BEFORE REPORTING group-data-name .
2.1 – group-data-name
is the name of a report group in a report group description entry in a Data Division. It must not appear in more than one USE statement.
3 – 3format DB-EXCEPTION
The USE statement specifies Declarative procedures to handle input/output errors and database exception conditions. It can also specify procedures to be executed before the program processes a specific report group. Format 3 - USE [GLOBAL] FOR DB-EXCEPTION [ON { {DBM$_exception-condition} ... }]. [ { OTHER }]
3.1 – DBM$ exception-condition
is a symbolic constant name beginning with the characters "DBM$_". It identifies a DBMS exception condition.