NULLCHAR
The following table describes the values that you can specify for this option:
Values for the NULLCHAR option
Value | Type | Description |
---|---|---|
? | String | (Default) Tells BMC AMI Unload to fill the null indicator field with the question mark character, '?' |
'c' | String | Tells BMC AMI Unload to fill the null indicator field with the character c, where c is any constant that is valid for C-type assembler language |
‘string’ | String | Tells BMC AMI Unload to specify the null indicator value and length. The length can be from 1 through 4 characters. |
HIVAL | Tells BMC AMI Unload to fill the null indicator field with high values | |
X'xx' | Tells BMC AMI Unload to fill the null indicator field with xx, where xx is any valid hexadecimal assembler constant, except X'00' | |
TRAILING | Position | (Default) Places the null indicator at the end of the field |
LEADING | Position | Places the null indicator at the start of the field |
UPFRONT | Position | Places null indicators for all nullable column in an array at the beginning of the record For example, if four nullable columns are in the record and the null marker is ?, the first and third are nulls, but the second and fourth are not. Therefore, there are four characters at the beginning of the record corresponding to the four nullable columns. These characters have the values in hexadecimal X'6F006F00', where X'6F' is ?. BMC AMI Unload uses this hexadecimal when converting from the CA Fast Unload product for Db2. The generated load statement has a NULLIF clause with correct position values in the null markers array. |
If you specify both the NULLTYPE and NULLCHAR options:
- The highest string value determines the null indicator length.
- The location value of the second option determines the null indicator position.
If the null indicator string value is 1-byte long, specifying NULLTYPE T2 or L2 duplicates it.
If you specify FORMAT DSNTIAUL, BMC AMI Unload overrides the NULLCHAR value to '?'.
When you download a nullable field from the table, BMC AMI Unload places a marker in the unloaded data trailing the field, leading it, or in front of the unloaded record. The marker may have from one to four characters.
The NULLCHAR specification must be coded immediately after FORMAT DSNTIAUL or FORMAT EXTERNAL.
The field content when its value is null is binary zeros. Conversely, when the nullable field is not null, the null marker is set to binary zeros.