Data Movement Utilities Guide and Reference
Command Syntax
>>-EXPORT TO--filename--OF--filetype---------------------------->
>-----+---------------------------+----------------------------->
| .-,-----------. |
| V | |
'-LOBS TO-----lob-path---+--'
>-----+---------------------------+----------------------------->
| .-,-----------. |
| V | |
'-LOBFILE-----filename---+--'
>-----+-----------------------------------+--------------------->
| .-----------------. |
| V | |
'-MODIFIED BY-----filetype-mod---+--'
>-----+--------------------------------------+------------------>
| .-,--------------. |
| V | |
'-METHOD N--(-----column-name---+---)--'
>-----+-------------------------+------------------------------->
'-MESSAGES--message-file--'
>-----+-select-statement---------------------------------------------+>
'-HIERARCHY--+-STARTING--sub-table-name--+---+---------------+-'
'-| traversal-order-list |--' '-where-clause--'
>--------------------------------------------------------------><
traversal-order-list
.-,-----------------.
V |
|---(-----sub-table-name---+---)--------------------------------|
Command Parameters
- HIERARCHY traversal-order-list
- Export a sub-hierarchy using the specified traverse order. All
sub-tables must be listed in PRE-ORDER fashion. The first sub-table
name is used as the target table name for the SELECT statement.
- HIERARCHY STARTING sub-table-name
- Using the default traverse order (OUTER order for ASC, DEL, or WSF files,
or the order stored in PC/IXF data files), export a sub-hierarchy starting
from sub-table-name.
- LOBFILE filename
- Specifies one or more base file names for the LOB files. When name
space is exhausted for the first name, the second name is used, and so
on.
When creating LOB files during an export operation, file names are
constructed by appending the current base name from this list to the current
path (from lob-path), and then appending a 3-digit sequence
number. For example, if the current LOB path is the directory
/u/foo/lob/path, and the current LOB file name is bar,
the LOB files created will be /u/foo/lob/path/bar.001,
/u/foo/lob/path/bar.002, and so on.
- LOBS TO lob-path
- Specifies one or more paths to directories in which the LOB files are to
be stored. When file space is exhausted on the first path, the second
path will be used, and so on.
- MESSAGES message-file
- Specifies the destination for warning and error messages that occur during
an export operation. If the file already exists, the export utility
appends the information. If message-file is omitted, the
messages are written to standard output.
- METHOD N column-name
- Specifies one or more column names to be used in the output file.
If this parameter is not specified, the column names in the table are
used. This parameter is valid only for WSF and IXF files, but is not
valid when exporting hierarchical data.
- MODIFIED BY filetype-mod
- Specifies additional options (see Table 2).
- OF filetype
- Specifies the format of the data in the output file:
- DEL (delimited ASCII format), which is used by a variety of database
manager and file manager programs.
- WSF (work sheet format), which is used by programs such as:
- Lotus 1-2-3
- Lotus Symphony
Note: | When exporting BIGINT or DECIMAL data, only values that fall within the range
of type DOUBLE can be exported accurately. Although values that do not
fall within this range are also exported, importing or loading these values
back may result in incorrect data, depending on the operating system.
|
- IXF (integrated exchange format, PC version), in which most of the table
attributes, as well as any existing indexes, are saved in the IXF file, except
when columns are specified in the SELECT statement. With this format,
the table can be recreated, while with the other file formats, the table must
already exist before data can be imported into it.
For more information about file formats, see Appendix C. Export/Import/Load Utility File Formats.
- select-statement
- Specifies the SELECT statement that will return the data to be
exported. If the SELECT statement causes an error, a message is written
to the message file (or to standard output). If the error code is one
of SQL0012W, SQL0347W, SQL0360W, SQL0437W, or SQL1824W, the export operation
continues; otherwise, it stops.
- TO filename
- Specifies the name of the file to which data is to be exported. If
the complete path to the file is not specified, the export utility uses the
current directory and the default drive as the destination.
If the name of a file that already exists is specified, the export utility
overwrites the contents of the file; it does not append the
information.
[ Top of Page | Previous Page | Next Page | Table of Contents | Index ]
[ DB2 List of Books |
Search the DB2 Books ]