DB2 Version 9.7 for Linux, UNIX, and Windows

Moving data across platforms - file format considerations

Compatibility is important when exporting, importing, or loading data across platforms. The following sections describe PC/IXF, delimited ASCII (DEL), and WSF file format considerations when moving data between different operating systems.

PC/IXF file format

PC/IXF is the recommended file format for transferring data across platforms. PC/IXF files allow the load utility or the import utility to process (normally machine dependent) numeric data in a machine-independent fashion. For example, numeric data is stored and handled differently by Intel and other hardware architectures.

To provide compatibility of PC/IXF files among all products in the DB2® family, the export utility creates files with numeric data in Intel format, and the import utility expects it in this format.

Depending on the hardware platform, DB2 products convert numeric values between Intel and non-Intel formats (using byte reversal) during both export and import operations.

Implementations of DB2 database based on UNIX operating systems not create multiple-part PC/IXF files during export. However, they allow you to import a multiple-part PC/IXF file that was created by DB2. When importing this type of file, all parts should be in the same directory, otherwise an error is returned.

Single-part PC/IXF files created on UNIX operating systems with the DB2 export utility can be imported by DB2 database for Windows.

Delimited ASCII (DEL) file format

DEL files have differences based on the operating system on which they were created. The differences are:
  • Row separator characters
    • Text files from UNIX operating systems use a line feed (LF) character.
    • Text files from other operating systems use a carriage return/line feed (CRLF) sequence.
  • End-of-file character
    • Text files from UNIX operating systems do not have an end-of-file character.
    • Text files from other operating systems have an end-of-file character (X'1A').

Since DEL export files are text files, they can be transferred from one operating system to another. File transfer programs can handle operating system-dependant differences if you transfer the files in text mode; the conversion of row separator and end-of-file characters is not performed in binary mode.

Note: If character data fields contain row separator characters, these will also be converted during file transfer. This conversion causes unexpected changes to the data and, for this reason, it is recommended that you do not use DEL export files to move data across platforms. Use the PC/IXF file format instead.

WSF file format

Numeric data in WSF format files is stored using Intel machine format. This format allows Lotus® WSF files to be transferred and used in different Lotus operating environments (for example, in Intel based and UNIX based systems).

Note: Support for this file format is deprecated and might be removed in a future release. It is recommended that you start using a supported file format instead of WSF files before support is removed.

As a result of this consistency in internal formats, exported WSF files from DB2 products can be used by Lotus 1-2-3® or Symphony® running on a different platform. DB2 products can also import WSF files that were created on different platforms.

Transfer WSF files between operating systems in binary (not text) mode.

Note: Do not use the WSF file format to transfer data between DB2 databases on different platforms, because a loss of data can occur. Use the PC/IXF file format instead.