Skip to content

Converting to DB2

Database Builder provides a wizard for converting tables into a DB2 database from any other supported database type. This wizard will convert the table structures from the current workspace's database into a DB2 database, then move all of the data.

To convert tables from the current workspace's database into a DB2 database, select Convert to DB2 from the Database menu. This brings up the Conversion Wizard.

Press Next, and the Select Source Tables page will be displayed where you should select the tables that you wish to convert.

The checkbox above the list of tables – Delete original table after conversion of table successfully completed – should be selected if you would like to delete the original tables after successful conversion. If any errors occur during conversion, the original tables will not be removed regardless of the selection you make here.

Once you have selected the tables, click the Next button so the wizard analyzes the selected tables. Click on Next again to continue with the conversion options.

For recnum tables, the Define Recnum Table Conversion page will be displayed listing all the tables identified as recnum tables. The checkbox Convert recnum tables to standard tables lets you choose whether you want to keep the table as a recnum table or not. If you choose to convert the tables to standard tables, you will need to select the indexes for all the tables listed.

After that, click on Next to move on to the Define Conversion Options page. On that page, enter the following:

Data Source

Enter the DSN that identifies the server and the DB2 database where you want to place the tables you are about to convert.

Login ID

Enter the user name to be used for authentication when you log on to the DB2 database.

Password

Enter the password for your user name.

Schema

Enter the name of the table schema to be used for the tables being converted.

Table Space for:

The Conversion Wizard allows you to set three different table spaces (refer to your DB2 documentation for more details on how to configure and manage database table spaces):

  • Table Data: Determines the table space to be used to store your data.
  • Index Data: Determines the table space to be used to store your indexes.
  • Long Data: Determines the table space to be used to store long or LOB table columns.

Store Data in ANSI Format

This option sets the table character format of the resulting table. If checked, data will be stored in ANSI format. If not checked, data will be stored in OEM format.

Convert Definition Only

Check this option if you want to create the tables in DB2 but do not want to have your data copied over to the DB2 database.

See Also