After the DB2 alter table field, new data cannot be added. The error sql0668n operation not allowed for Reason code "7" on tab is returned.

Source: Internet
Author: User

To change the field attributes of a DB2 table:

Alter table schema. tablename alter comlun colname set datatype varchar (32 );

After the execution, an error is reported when inserting data into the table:

Sql0668n operation not allowed for Reason code "7" on table "db2inst1. EMP ".

Sqlstate = 57016


DB2 => load query table schema. tablename

View the table status:


Reorg pending

In execution

DB2 => reorg table
Schema. tablename

Then you can insert data.

Conclusion: when modifying the attribute of a DB2 table field or adding a field, you must execute the reorg table tablename statement after the statement is executed.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.