Fields of the interface control block
Use the fields of the interface control block to pass information to and from your exit routine.
Although there are separate interface control blocks that work with Assembler, PL/I, or COBOL, the fields of the interface control block are standard regardless of the programming language in which your edit exit routine is written. These fields are shown in the following table. Unless otherwise stated, each field relates to all formatting calls.
- For High-Level Assembler, use DSECT DXEECSA
- For PL/I, use copy file DXEECSP
- For COBOL, use copy book DXEECSC
|ECSDECPT||Contains the current decimal point symbol as determined by the DECOPT option of the QMF profile (period or comma).|
|ECSECODE||Contains the user edit code.|
|ECSERRET||Contains a zero at the point of call.
Set this to a nonzero return code to record an error. Use one of the
values in the following list for an error of the indicated type:
The error codes listed (and their associated messages and help panels) are specific to the error. For any other code, a general error message, with a general help panel, is displayed.
|ECSFREQ||Holds E for a formatting call, T for a termination call.|
|ECSINDTA||Contains information about the value to be formatted.|
|ECSINLEN||Contains the length, in bytes, of the value to be formatted.|
|ECSINNUL||Holds an N if the value to be formatted is null.|
|ECSINPRC||Contains the precision of the value to be formatted. Applies only to U-type codes when the data type is DECIMAL, or to V-type codes when the character string to be formatted was derived from numeric data.|
|ECSINSCL||Contains the scale of the value to be formatted. Applies only to U-type codes when the data type is DECIMAL, or to V-type codes when the character string to be formatted was derived from numeric data.|
|ECSINSGN||Holds the sign of a converted numeric value (blank or - ). Applies only to V codes when the character string to be formatted was derived from numeric data.|
|ECSINTYP||The internal database representation
of the data type of the value to be formatted. The
code shown here for each data type is the same as the value that appears
in the SQLTYPE field of the SQLDA.
|ECSNAME||Contains the name of the control block, which is DXEECS. Serves as an eye catcher in storage dumps.|
|ECSRQMF||Set this to T to request a termination call.|
|ECSRSDTA||Contains information about the formatted result.|
Contains the length of the output area, in bytes. (This value is taken from the WIDTH column of the QMF form.) Do not use more memory in the output area than is indicated by the value in the ECSRSLEN field, or you will see error DSQ60439: User edit program memory overwrite.
|ECSTHSEP||Contains the thousands separator as determined by the DECOPT option of the QMF profile (blank or a comma).|
|ECSUSERS||A 256-byte scratchpad area where your exit routine can record information that persists from one call to the next. On the first call after the edit routine is loaded, this field contains binary zeros.|