Transferring Data to BASIC Sequential Files

The following list describes how iSeries, eServer™ i5, or System i5® data created by a BASIC-sequential-file-defined data definition changes:
  • Hexadecimal fields change to equivalent ASCII characters for each half-byte. Double quotation marks surround them.

    For example, X'F3' expands to ASCII 22443322 and is written to the file.

  • EBCDIC character, date, time, and time-stamp fields change byte by byte and are mapped into ASCII characters as defined by the translation tables. ASCII double quotation marks are added before and after the character string.
  • Null fields are represented by the absence of the field (comma comma, or by a single comma if the null field is the last field of the record).
  • For null fields, successive commas in the file will result in a null value being sent to the iSeries, eServer i5, or System i5 if the field is null-capable.
  • In variable-length fields, if the iSeries, eServer i5, or System i5 field is variable length, the field is converted to the iSeries, eServer i5, or System i5 variable-length format.
  • Binary fields change to ASCII numeric. Leading zeros to the left of the decimal point and trailing zeros to the right of the decimal point are removed.

    For example, X'FFD3' appears as ASCII 2D3435. When displayed on an ASCII device, the string appears as -45.

  • Zoned decimal fields change to ASCII numeric. Leading zeros to the left of the decimal point and trailing zeros to the right of the decimal point are removed.

    For example, EBCDIC F0F0F9F5F2D6 with a field length that indicates two digits to the right of the decimal point expands to ASCII 2D39352E3236. The string appears as -95.26 when an editor displays it or it prints.

  • Packed decimal fields change to ASCII numeric. Leading zeros to the left of the decimal point and trailing zeros to the right of the decimal point are removed.

    For example, X'871F' (no decimal point) changes to ASCII 383731. The string appears as 871 when an editor displays it or it prints.