DataLoader/MX Reference Manual (G06.24+)
Creating a Customized Version of DataLoader/MX
DataLoader/MX Reference Manual—525872-002
5-5
CONVERTIT
The syntax is:
This exit provides a way to pass parameters to other user exits. When you process a
parameter that you recognize, save whatever information from it that you need for your
global variables so that it is accessible to other user exits. If the parameter is one that
is recognized by your user exits, it should be processed and a nonzero value returned
in Status. If is not recognized, a 0 (zero) value should be returned in Status.
CONVERTIT
The CONVERTIT exit is called when you explicitly request it by specifying either an
uppercase or lowercase letter C (c) in the list of user exits associated with the -X
parameter. Its purpose is to convert the record passed it into a format suitable for
processing by subsequent user exits or by the output file. This exit is usually the first
user exit to be called.
The syntax is:
To minimize unnecessary data movement, CONVERTIT can either convert the record
in the same place it was passed to CONVERTIT (such as in RecIn) or build the
converted record in the output buffer provided (such as in RecOutBuf). If the record is
converted in place, its new length is returned in RecInLen. If the converted record is
built in RecOutBuf, its length is returned in RecOutLen.
Both RecIn and RecOutBuf are buffers whose length is RecOutBufLen bytes long.
You can extend the record, even when converting in place in RecIn, as long as the
new length is less than RecOutBufLen bytes.
The value of Status indicates where the converted record is located. If the converted
record appears in RecIn, set Status to a value of 1. If the converted record appears
in RecOutBuf, set Status to a value of 2.
If CONVERTIT is unable to do the conversion, it should return a negative value in
Status. To stop processing this record and go back to the read cycle for the next
record without executing the write record logic and partition boundary estimation logic,
set Status to 0 (zero).
void CHECKARG( char* Arg, long* ArgLen, short* Status )
void CONVERTIT(char* RecIn,
long* RecInLen,
char* RecOutBuf,
long* RecOutBufLen,
long* RecOutLen,
short* Status )