The extract exit

The extract exit is invoked at various points during processing of the EXTRACT command.

The points are listed in When the user program is invoked.
Note:
  1. If you do not specify an EXTRACT user exit routine on the entry linkage to DFHCSDUP, or on the USERPROGRAM keyword, a syntax error occurs.
  2. A user exit routine specified on the USERPROGRAM keyword is used in preference to one specified on the entry linkage.
When invoked
Invoked multiple times during processing of the EXTRACT command.
Exit-specific parameters
EXTRACT_FUNCTION_CODE_PTR
Address of a halfword containing a code that defines the point in EXTRACT processing reached. The EXTRACT function codes are listed in EXTRACT function codes.
EXTRACT_WORK_AREA_PTR
Address of a fullword containing the address of the EXTRACT work area.
EXTRACT_BACKTRAN_COMMAND_PTR
Address of a fullword containing the address of the EXTRACT command being processed.
EXTRACT_CSD_LIST_NAME_PTR
Address of an 8-byte field containing the name of the list whose data is being extracted. This value is set only on ‘list start' and ‘list end' calls.
EXTRACT_CSD_GROUP_NAME_PTR
Address of an 8-byte field containing the name of the group whose data is being extracted. This value is set on ‘group start', ‘group end', ‘object start', ‘object end', and ‘keyword' calls.
EXTRACT_CSD_OBJECT_TYPE_PTR
Address of a 12-byte field that identifies the type of object (such as TRANSACTION, PROGRAM, and so on). This value is set only on ‘object start', ‘object end', and ‘keyword' calls.
EXTRACT_CSD_OBJECT_NAME_PTR
Address of an 8-byte field containing the name of the object. This value is set only on ‘object start', ‘object end', and ‘keyword' calls.
EXTRACT_KEYWORD_NAME_PTR
Address of an 12-byte field containing the name of the keyword being processed. This value is set on ‘keyword' calls only.
EXTRACT_KEYWORD_LENGTH_PTR
Address of a halfword containing the length of the value associated with the keyword. This value is set on ‘keyword' calls only.
EXTRACT_KEYWORD_VALUE_PTR
Address of a character string which contains the value associated with the keyword. This value is set on ‘keyword' calls only.

Note that these parameters are similar to those passed when DFHCSDUP is invoked as a batch program. (See Parameters passed from DFHCSDUP to the user program.) However, when DFHCSDUP is invoked from a user program, the parameter list also includes the standard parameters mentioned under Parameters passed to the user exit routines.

Return codes
UERCNORM (X'00')
Continue processing.
UERCERR
Irrecoverable error. This causes DFHCSDUP to terminate with a return code of ‘8'.
XPI calls
Must not be used.