Skip to main content

         This documentation site is for previous versions. Visit our new documentation site for current releases.      

Importing schema changes with columns that require changes on IBM DB2 z/OS

Updated on July 26, 2021

On IBM DB2 z/OS, some column changes cannot be applied automatically, such as changing a column constraint from Null to Not Null. When you import schema changes, if the column cannot be changed automatically, the generated DDL includes the statement "change not allowed by DB2 zOS".

Work with your z/OS database administrator to modify the column and apply the necessary constraints. Pega recommends that you perform one of the following procedures:

Using the INSERT INTO SELECT statement

Modify a column and apply constraints with the INSERT INTO SELECT statement.

  1. Create a new table with the column change requirement and with no data.
  2. Copy the data from the original table by using the following statements:

INSERT INTO new_table

SELECT * FROM original_table

  1. Drop or rename the original table.
  2. Rename the new table with the same name as the original table. The new table must be in the same tablespace and schema as the original table.

Using the z/OS batch utility

Modify a column and apply constraints with the z/OS batch utility.

  1. Use the batch utility to unload the original table.
  2. Drop the table.
  3. Create a new table with the same name as the original table, with the required column change.

The batch utility includes the DDL of the original table. You can use this DDL to create the new table by modifying the column and adding the new constraint.

  1. Load the original data into the new table.

Have a question? Get answers now.

Visit the Support Center to ask questions, engage in discussions, share ideas, and help others.

Did you find this content helpful?

Want to help us improve this content?

We'd prefer it if you saw us at our best. is not optimized for Internet Explorer. For the optimal experience, please use:

Close Deprecation Notice
Contact us