Dataloader/MP Reference Manual
Table Of Contents
- What’s New in This Manual
- About This Manual
- 1 Introduction to DataLoader/MP
- 2 DataLoader/MP Components
- 3 Running DataLoader/MP
- 4 Specifying File-Related Options for DataLoader/MP
- 5 Creating a Customized Version of DataLoader/MP
- User Exits
- User Exit Descriptions
- BUILDKEY
- CHECKARG
- CONVERTIT
- DELETEIT
- DONEWITHTRANSACTION
- EXITSDESCRIPTION
- GETNEXTRECORD
- INITIALIZE1
- INITIALIZE2
- INSERTIT
- INSTRUCTIONS
- MISC1, MISC2, MISC3, and MISC4
- NEWTRANSACTION
- NEXTINDIRECTFILE
- SKIPPING
- STATISTICSTIME
- TERMINATING
- T0330U00_DEFAULTEXITS_C
- T0330U00-DEFAULTEXITS-COBOL
- T7900D41_DEFAULTEXITS_C
- T7900V00-DEFAULTEXITS-COBOL
- UPDATEIT
- Default User Exits
- DataLoader/MP Library
- The MAKE Routine for NM DataLoader/MP
- The MAKE Routine for Nonnative Mode DataLoader/MP
- 6 DataLoader/MP Examples
- 7 Recovery Strategies
- A Error and Warning Messages
- B Processing Flowcharts
- C C-Only Error Functions
- Index

Creating a Customized Version of DataLoader/MP
DataLoader/MP Reference Manual—424148-003
5-21
User Messages—C
If -2 is specified in FileNum, the data is written to the file specified in the -O=
parameter.
The value returned by this procedure is the actual number of bytes written. This value
is usually the number of bytes requested to be written, but can be smaller if writing to a
file whose record length is smaller than Len, or greater if the file is an unstructured file
without the ODDUNST attribute, and Len is odd.
If the KEYRANGE interpretation is used for output, the DTLWrite utility always calls the
BUILDKEY exit.
There are no error returns. Any errors are handled by DataLoader/MP.
User Messages—C
The following procedures can be used to communicate with the user. In all cases, the
message to be written is specified by using the standard C print format as indicated by
(char* Format, ... ).
DTLContinue
This procedure writes the message to the process’s stderr then displays a prompt
asking if the user would like to continue. If the user indicates yes, the return value of
this procedure is nonzero. If the user indicates no, the return value of the procedure is
zero (0).
The syntax for this procedure follows:
DTLFatalErr
This procedure writes the message to stderr and to stdout (unless stdout is the same
as stderr). It ignores -Q so that the message appears at least on stderr. After the
message is written, DTLFatalErr calls the TERMINATING user exit, passing 0 as the
argument. Then it closes the error file (the -E file or stderr). Finally, it calls exit(3).
DTLFatalErr does not return.
The syntax for this procedure follows:
Note. There are two versions of each User Messages routine: one is designed for use with C,
and the other is designed for use with COBOL. Two versions exist because, although it is
common practice for C routines that print messages to accept a variable parameter list,
COBOL cannot call routines that have variable parameter lists. Therefore, for each C User
Message routine, a corresponding one exists for use by COBOL. Its name is the same as the
name of the C routine except that it is in all uppercase, has the letters COB appended, and its
parameters are the message and the length of the message. The calling COBOL program
must format the message.
short DTLContinue( char* Format, ... );
void DTLFatalErr( char* Format, ... );