Rebuilding Target Tables Containing LONG VARCHAR Columns
This topic describes how to rebuild tables in the target database that contain LONG VARCHAR columns.
In previous Siebel CRM releases, LONG columns in the Siebel repository were mapped to LONG VARCHAR columns on z/OS databases. The DDLIMP utility has now been modified so that LONG columns are created on z/OS as VARCHAR columns with a maximum size of 16,350 characters. This change to DDLIMP can result in inconsistencies between the staging database, on which LONG columns are mapped to columns with a maximum size of 16,350, and the target database where a LONG VARCHAR column can be much larger.
The Siebel upgrade process requires that the staging database represents the target schema to be upgraded so differences in column definitions can cause issues during the upgrade. For example, a Siebel target table in a 32-KB table space can have a LONG VARCHAR column whose length exceeds 16,350 characters. However, when the same column is created in the staging database, it has a maximum length of 16,350 characters. In these circumstances, if the upgrade process attempts to add columns to the staging table as an additive change it will succeed, but will fail when the changes are applied to the target database.
To avoid potential issues during the target database upgrade, if a table in the target database resides in a table space within a 32-KB buffer pool, and if the number or size of the table columns will be increased during the upgrade process, then the table must be re-created so that it has the same column definitions as the corresponding staging database table.
To rebuild target tables that contain LONG VARCHAR columns
Determine which target tables containing LONG VARCHAR columns need to be re-created.
To do this, edit and then run the sample code listed in Sample Code for Generating a List of Tables to Rebuild.
Unload data from each non-empty table included in the list.
Drop each of the tables included in the list, including empty tables.
Synchronize the target database logical and physical schemas by launching the Database Configuration Wizard and selecting the Synchronize Schema Definition option. Specify values as follow:
When prompted to enter the database user name and password, specify values for the target database.
When prompted for the name of the repository with which the existing Siebel database is to be synchronized, specify the following values:
Production upgrades: Siebel Repository
Development upgrades: Prior Customer Repository
The Wizard generates the DDL required to synchronize the Siebel database and the Siebel Repository. If you did not select the Run DDL Automatically installation option, then the Wizard generates files that you must apply on the z/OS database to re-create the tables you dropped in the previous step.
Reload the tables with the data that you unloaded in step 2.
For detailed information on running the Synchronize Schema Definition process, see Implementing Siebel Business Applications on DB2 for z/OS.