Reading data using external tables

You can configure Db2 connector to read data using external tables. Refer to DB2 connector support for external tables for information on databases that can be used.

Before you begin

You must configure a database connection for the Db2® connector.


  1. On the job design canvas, double-click the Db2 connector icon.
  2. Click the Output tab, then select the output link that you want to edit.
  3. Click the Properties tab.
  4. On the Properties tab in the Usage section, specify how the connector operates in a job.
    1. In the Table name field, specify the table that you want to read.
    2. Set the Generate SQL property to Yes.
    3. Set the Session > Use external tables property to Yes.
    4. If needed, configure external table configuration properties.
    5. You can configure other Db2 connector properties that are available in current mode.
  5. Click OK
    External table mode configuration properties in read mode
    You can provide additional properties to control read operation when external tables are used. When no values are defined, defaults will be used.
    • Directory for named pipe (Unix only)
      • Type: String
      • Specifies the location where the named pipe that is used by the external tables operation must be created. This property applies to Unix systems only.
    • Other options
      • Type: String
      • Extra options to be passed to the external table statement. The supported values are described in the Create External Table section of the IBM Knowledge Center that is dedicated to target Db2 database. Note, that some of the options are already in use to allow read and write operation within the DataStage job and cannot be redefined inside the Other options property. Refer to troubleshooting section for additional information.