Entry parameters for table-level and row-level user exits in COBOL
The following list describes each parameter in the entry parameter list that must be defined in each COBOL table/row-level user exit program.
- Return Code (LK-RETURN-CODE)
- The return code that indicates whether or not the user exit program was successful. In the user exit program, return an error message ID if errors occurred in the user exit program or blank characters if no errors occurred in the user exit program.
- User Exit Program Name (LKPROGRAM)
- The name of the user exit program that was called. This is the name of the program that you specify in Management Console.
- User Exit Point (LK-ENTRY)
- The table/row-level user exit point where the user exit program was called.
- Publisher Before Image (LK-BEFORE-RECORD)
- The row before image in the source table.
- Publisher After Image (LK-AFTER- RECORD)
- The row after image in the source table.
- Publisher Before Image NULL Indicator Count (LK BEFORE-NULLIND-CNT)
- The number of NULL-capable fields in the before image. Each NULL-capable field will have a NULL indicator.
- Publisher After Image NULL Indicator Count (LK-AFTER-NULLIND-CNT)
- The number of NULL-capable fields in the after image data. Each NULL-capable field will have a NULL indicator.
- Publisher Before Image NULL Indicators (LK-BEFORE-NULLINDS)
- NULL indicators for all NULL-capable fields in the before image.
- Publisher After Image NULL Indicators (LK-AFTER-NULLINDS)
- NULL indicators for all NULL-capable fields in the after image.
- Publisher Before Image Journal Data (LK-BEFORE-JOURNAL)
- Journal control information associated with the before image.
- Publisher After Image Journal Data (LK-AFTER-JOURNAL)
- Journal control information associated with the after image data.
- Subscriber Final Image Length (LK-DATA-LENGTH)
- The length of the fully formatted (final) image that will be applied to the target table.
- Subscriber Final Image (LK-DM-BUFFER)
- The fully formatted (final) image that will be applied to the target table. The fully formatted image contains the results of data transformations that may have been applied to the replicated after image in the target environment. For target tables that have been assigned under summarization, row consolidation (one-to-one and one-to-many), and adaptive apply, this image, in before user exit program invocations, will contain only default values (blanks, zeroes, and so on) instead of the final image.
- Subscriber Final Image NULL Indicator Count (LK DM-NULLIND-CNT)
- The number of NULL-capable fields in the fully formatted (final) image. Each NULL-capable field will have a NULL indicator.
- Subscriber Final Image NULL Indicators (LK-DM-NULLINDS)
- NULL indicators for all NULL-capable fields in the fully formatted (final) image
- Source identifier (LK-SYSTEMID)
- The source identifier identifying the subscription containing the source table. Source identifiers and subscriptions are defined in Management Console.
Both the LK-BEFORE-JOURNAL and LK-AFTER-JOURNAL variables in the linkage section contain the journal control fields listed in Entry parameters for table-level and row-level user exits in RPG.