When (and when not) to use the Import utility

The Import utility provides one method for moving Db2® data between different Db2® subsystems (that is, export on one subsystem followed by import on another). If you want to move data between tables in the same Db2® sub-system, either the Copy utility or direct execution of SQL statements is typically more convenient.

In general terms, the Import utility is suitable for inserting small to medium volumes of data into Db2® tables. Import operations are achieved by inserting each selected record in the import data set into the target table, and any update operations are achieved by generating an update statement.

All insert and update operations are logged by Db2®, which can have operational and performance implications. The Import utility is not intended as a substitute for the Db2® utilities if unloading or migrating large volumes of data, and the Db2® utilities offer superior performance in these situations. Whenever possible, run import operations in batch.

The import utility provides for automatic mapping of the Db2® null indicator, and, optionally, one of the following formats can be specified corresponding to the template used:
  • FM/Db2 (SQLDA) format
  • Db2® unload format
  • DSNTIAUL format
  • User defined format (excluding Placement, User defined)
However, the template editor does not show the null indicator as a separate item in the "From" template on the Field Mapping panel. It is therefore not possible to re-map the null indicator associated with nullable columns to a column in the target table.

Related tasks

Related references