
In the following, external data format identifies the coding of a field value in the source or target file, and column type identifies the type of a table column as it was declared when defining the table.
The following external data formats are processed by LOAD:
CHAR according to the computer, ASCII or EBCDIC code; maximum length is 254 bytes
INTEGER binary code (machine specific) 1, 2, or 4 bytes long, sign in bit 0, negative values in two's complement form
REAL floating point representation with mantissa and exponent, 4 or 8 bytes long, in machine-specific representation
DECIMAL packed decimal: one digit per half byte, sign coded in the rightmost half byte, 1 to 10 bytes long, at most 18 digits, the position of the virtual decimal point is derived from the type of the table column
DECIMAL(n) n specifies the number of digits to the right of the virtual decimal point
ZONED zoned decimal: allowed are the /370 Zoned Data Format, the COBOL Standard Zoned Data Representation, as well as COBOL Zoned Data With Leading Sign, and COBOL Zoned Data With Trailing Sign in separate position, 1 to 18 bytes long, the position of the virtual decimal point is derived from the type of the table column
ZONED(n) n specifies the number of digits to the right of the virtual decimal point
Examples of type declarations in different programming languages:


Information concerning DATALOAD and DATAUPDATE:
Any numerical data format (INTEGER, REAL, DECIMAL, ZONED) can be converted into any numerical column type (FIXED, SMALLINT, INTEGER, FLOAT).
ASCII/EBCDIC coded values can be converted into any column type.
REALs must be coded in the form that is specific to the computer. They cannot be transferred between computers of different types. INTEGER values are interpreted as signed values. Their representation can be adapted (e.g., for DATALOAD) using the file option INTEGER. ZONED and DECIMAL values have a defined coding; i.e., they are not a problem.
Information concerning DATAEXTRACT:
The numerical data types FIXED, SMALLINT, and INTEGER can be converted into all listed data formats.
If an overflow occurs when a FIXED, SMALLINT, or INTEGER column value is converted into an external INTEGER value, asterisks ("*") instead of the binary number are inserted into the data field, and the extract run is aborted.
Limiting values are for a
1-byte integer : -128 and +127
2-byte integer : -32768 and +32767
4-byte integer : -2147483647 and +2147483647
The numerical data type FLOAT can be output in any CHAR format or as REAL.
