The Header record specifies your source, the database you are interfacing to, and your chosen options for the return of acknowledgments and messages.
Header record commands are listed in the following below, and usage rules follow.
Command | Abbreviation | Operand Details |
---|---|---|
DESTINATION; | DES; | database |
ORIGIN; | ORI; | origin of 1 through 9 alphanumeric characters |
(Used for identification of data file in recovery) | ||
SOURCE; | SR; | This is the media: its value is always PROG |
REQD.ACK; | RQA; | Y or YES if require acknowledgment of input |
N or NO if acknowledgment not required | ||
ERROR.MSG; | ERM; | Y or YES if require error messages returned |
N or NO if error messages not required | ||
LOG; | Y or YES if require GLI to print error log | |
N or NO if printing of error log not needed |
If there is an error in the Header record, the GLI program returns a FATAL message and goes to EOJ.
Rules for Header Records
The following rules apply to Header records:
There must be exactly one Header record and it must be the first input record. Positions 1 through 6 must contain the value HEADER. The remaining positions are free-format, containing commands and valid operands with one or more following separating spaces.
All commands terminate with a semicolon.
All commands except LOG are mandatory.
REQD.ACK; YES is required if ERROR.MSG; YES is specified.
If REQD.ACK; YES is specified, then acknowledgment messages are returned to the input source. Refer to GLI Output for more information.
If ERROR.MSG; YES is specified, all error messages for a transaction are also returned to the input source. Refer to GLI Output for more information.
Example
An example of a HEADER record follows.
HEADER DES;XXXDB SOURCE;PROG ORI;ZZZDB ERM;Y REQD.ACK;YES LOG;Y