XULDSTMT (unload DDL statement) automation control point
Use the XULDSTMT automation control point to review and/or modify the generated DDL for the LOAD DATA statement that corresponds to the object that is being unloaded.
The product invokes this automation control point after all applicable rows have been physically unloaded from a table.
Variables
The following table describes the variables used in the XULDSTMT automation control point:
Variable name | Contents | Possible values | Notes |
|---|---|---|---|
loadstmt | Generated DDL for the LOAD DATA statement that will be written to SYSPUNCH | Not applicable | |
lrecl | Local record length of the output file to which the LOAD DATA statement will be written | Not applicable | This variable is read-only. If you change this value, it does not affect the actual LRECL. |
recfm | Record format of the LOAD DATA statement file |
| This variable is read-only. If you change this value, it does not affect the actual RECFM. |
tbcreator | Table creator name | Not applicable |
|
tbname | Table name | Not applicable |
|
Return codes
The XULDSTMT automation control point returns the following return codes:
Return code | Description |
|---|---|
0 | (default value) Signifies normal completion No action is required. |
Any other value | Abnormal termination Set the return code to any non-zero value to cancel the entire job. |
Usage considerations
The loadstmt variable is a numbered series of lines of characters (a stem variable). loadstmt.0 contains the number of lines that the proposed LOAD DATA statement occupies. You can change this stem or the number of elements in the array, but loadstmt.0 must match the number of lines to be written. (For example, if the LOAD DATA statement contains 15 lines of characters, the value of loadstmt.0 must be 15). The following table shows an example representation of this variable:
Numbered variable | Line string value |
|---|---|
loadstmt.o | 14 (the number of individual lines in the LOAD DATA statement) |
loadstmt.1 | LOAD DATA INDDN OUTDSET |
loadstmt.2 | INTO TABLE 'DSN8DCAT'.'TEST_MANYVC_TBL1 ' |
loadstmt.3 | ( |
loadstmt.4 | 'COL001' POSITION(1:11) INTEGER EXTERNAL (11) |
loadstmt.5 | NULLIF(10)=' 0' |
loadstmt.6 | ,'COL002' POSITION(12:21) CHAR (10) |
loadstmt.7 | NULLIF(12:21)=' ' |
loadstmt.8 | ,'COL003' POSITION(22:41) CHAR(20) |
loadstmt.9 | NULLIF(22:41)=' ' |
loadstmt.10 | ,'COL004' POSITION(42:66) CHAR(25) |
loadstmt.11 | NULLIF(42:66)=' ' |
loadstmt.12 | ,'COL005' POSITION(67:96) CHAR(30) |
loadstmt.13 | NULLIF(67:96)=' ' |
loadstmt.14 | ) |