Error case for DB2 database integrity pending sql0668n

Source: Internet
Author: User
Tags db2 table name terminates

The error number is: sql0668n

Detailed Description:

SQL0668N does not allow action on table ' < table name designtimesp=24220> ', Reason code.

Explain:

Restrict access to table ' < table name designtimesp=24224> '. The reason is based on the following reason code

Reason code:

1 The table is in the "Set integrity pending no access" status. The integrity of the table is not enforced and the contents of the table may be invalid. If the

The genus table is in the "Set integrity pending No access" state, for a parent table or base that is not in the "Set integrity pending no access" state

This error may also be received by actions performed by the list.

The 2 table is in the No data movement state. Suppresses the operation that causes data movement when in this state. Data movement operations include redistribute, update of database partitioning keys, update of multidimensional cluster keys, update of range cluster keys, update of data partitioning keys, and REORG TABLE.

The 3 table is in the Mount pending state. The previous load attempt on this table failed. The table is not allowed to be accessed until the load operation is restarted or terminated.

4 tables are in the Read access state. This state can occur during online mount (load) processing (load insert with the READ ACCESS option) or after an online mount (load) operation, except when using the set INTEGRITY

Statement before all constraints are validated by the newly appended portion of the table. Update activity on this table is not allowed.

The 5 table is in the "Loading" state. The load utility currently operates on this table until the load completes to allow access.

6 The Materialized query table referencing the nickname cannot be refreshed in ESE.

The 7 table is in the REORG suspend state. This can occur after executing the ALTER TABLE statement that contains the REORG recommended action.

The 8 table is in the "Change pending" state. This can occur when the table is used in the unit of work in which the ALTER TABLE statement contains the REORG recommended action.

User response:

1 perform a setintegrity statement with the IMMEDIATE CHECKED option on table "< table name designtimesp=24243>" To leave the table out of the "set integrity pending Access" state. For a user-maintained materialized query table, execute the statement with the immediate unchecked option, rather than with the immediatechecked option.

2 Pairs of table "< table name designtimesp=24245>"

Subordinates immediately materialize the query table and the staging table executes the REFRESH table statement. You can use the previous LOAD insert operation based on the Append data for < table designtimesp=24248> and the ALTER TABLE statement with the previous attach clause to base the < table name designtimesp=2424 9> "'s connection data to incrementally maintain the contents of the query table and the staging table for immediate materialization of these dependencies.

3 restarts or terminates a previously failed load operation on this table by issuing a load with the restart or Terminater option, respectively.

4 issuing LOAD QUERY

command to check whether the table is being loaded. If so, wait until the load utility completes, or, if necessary, restarts or terminates a previously failed mount operation. If the load is not currently in progress, a SET integrity statement with the IMMEDIATE CHECKED option is issued to verify the constraints in the newly installed part of the table.

5 waits until the current LOAD operation completes. You can use the Load Query command to monitor the progress of a mount.

6 using Maintain by user

Options define materialized query tables. The materialized query table is then populated with an INSERT statement with a subquery.

7 Use the REORG Table command to reorganize tables (note that InPlace REORG table is not allowed for tables in the REORG pending state).

8 Complete the unit of work and then issue the command again.

Sqlcode:-668

sqlstate:57007

-------------------------------------------------------

Solution:

Execute the following commands on the server-side CLP:

SET INTEGRITY for Db2admin. Alarmtarget IMMEDIATE CHECKED

Note: If the table is in the "Set integrity suspend" state, then you need to deal with it as soon as possible, otherwise the table can not be SELECT, update, delete, and other operations.

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: info-contact@alibabacloud.com 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.