DB2 - Problem description
Problem IC99952 | Status: Closed |
USING ADMIN_MOVE_TABLE ON TABLE WITH GENERATED COLUMN REFERENCED BY MDC KEY RESULTS IN SQL20209N | |
product: | |
DB2 FOR LUW / DB2FORLUW / A50 - DB2 | |
Problem description: | |
Given a table whose DDL defines a table with a generated column referenced by a MDC key, doing ADMIN_MOVE_TABLE will result in SQL20209N. admin_move_table calls "set integrity on XXXX all immediate unchecked" of which "immediate unchecked" can't be used on a table with a generated column. Example of errors from CLP in FP2: db2 "call ADMIN_MOVE_TABLE('T996463','TEQUIPMENT','USERSPACE1','USERSPACE1 ','USERSPACE1','',NULL,'',NULL,'COPY_USE_LOAD \"COPY YES TO /home/denisyhw/pmr/51349/temp\",NO_STATS,NO_AUTO_REVAL,NON_CLUST ER','MOVE')" SQL2104N The ADMIN_MOVE_TABLE procedure could not be completed at this time by this user. Reason code: "4". SQLSTATE=5UA0M db2 "call ADMIN_MOVE_TABLE('T996463','TDETECTOR_SITE','USERSPACE1','USERSP ACE1','USERSPACE1','',NULL,'',NULL,'COPY_USE_LOAD \"COPY YES TO /home/denisyhw/pmr/51349/temp\",NO_STATS,NO_AUTO_REVAL,NON_CLUST ER','MOVE')" SQL2104N The ADMIN_MOVE_TABLE procedure could not be completed at this time by this user. Reason code: "4". SQLSTATE=5UA0M db2 "call ADMIN_MOVE_TABLE('T996463','TREADING2','USERSPACE1','USERSPACE1' ,'USERSPACE1','',NULL,'',NULL,'COPY_USE_LOAD \"COPY YES TO /home/denisyhw/pmr/51349/temp\",NO_STATS,NO_AUTO_REVAL,NON_CLUST ER','MOVE')" SQL2104N The ADMIN_MOVE_TABLE procedure could not be completed at this time by this user. Reason code: "4". SQLSTATE=5UA0M db2 "call ADMIN_MOVE_TABLE('T996463','TTRAIN','USERSPACE1','USERSPACE1','U SERSPACE1','',NULL,'',NULL,'COPY_USE_LOAD \"COPY YES TO /home/denisyhw/pmr/51349/temp\",NO_STATS,NO_AUTO_REVAL,NON_CLUST ER','MOVE')" SQL2104N The ADMIN_MOVE_TABLE procedure could not be completed at this time by this user. Reason code: "4". SQLSTATE=5UA0M Example of errors that appear for FP3: db2 "call ADMIN_MOVE_TABLE('T996463','TEQUIPMENT','USERSPACE1','USERSPACE1 ','USERSPACE1','',NULL,'',NULL,'COPY_USE_LOAD \"COPY YES TO /home/denisyhw/pmr/51349/temp\",NO_STATS,NO_AUTO_REVAL,NON_CLUST ER','MOVE')" SQL20209N The "GENERATED COLUMN" option is not valid for table "T996463.TREADING2" with reason code "8". SQLSTATE=428FH db2 "call ADMIN_MOVE_TABLE('T996463','TDETECTOR_SITE','USERSPACE1','USERSP ACE1','USERSPACE1','',NULL,'',NULL,'COPY_USE_LOAD \"COPY YES TO /home/denisyhw/pmr/51349/temp\",NO_STATS,NO_AUTO_REVAL,NON_CLUST ER','MOVE')" SQL20209N The "GENERATED COLUMN" option is not valid for table "T996463.TREADING2" with reason code "8". SQLSTATE=428FH db2 "call ADMIN_MOVE_TABLE('T996463','TREADING2','USERSPACE1','USERSPACE1' ,'USERSPACE1','',NULL,'',NULL,'COPY_USE_LOAD \"COPY YES TO /home/denisyhw/pmr/51349/temp\",NO_STATS,NO_AUTO_REVAL,NON_CLUST ER','MOVE')" SQL0270N Function not supported (Reason code = "52"). SQLSTATE=42997 db2 "call ADMIN_MOVE_TABLE('T996463','TTRAIN','USERSPACE1','USERSPACE1','U SERSPACE1','',NULL,'',NULL,'COPY_USE_LOAD \"COPY YES TO /home/denisyhw/pmr/51349/temp\",NO_STATS,NO_AUTO_REVAL,NON_CLUST ER','MOVE')" SQL0668N Operation not allowed for reason code "10" on table "T996463.TREADING2". SQLSTATE=57016 | |
Problem Summary: | |
**************************************************************** * USERS AFFECTED: * * ALL * **************************************************************** * PROBLEM DESCRIPTION: * * See Error Description * **************************************************************** * RECOMMENDATION: * * Upgrade to 10.5 fp3 or later * **************************************************************** | |
Local Fix: | |
Drop the foreign keys, do admin_move_table, then reinstall the keys. | |
available fix packs: | |
DB2 Cancun Release 10.5.0.4 (also known as Fix Pack 4) for Linux, UNIX, and Windows | |
Solution | |
First fixed in DB2 version 10.5 fix pack 4 | |
Workaround | |
not known / see Local fix | |
Timestamps | |
Date - problem reported : Date - problem closed : Date - last modified : | 10.03.2014 08.09.2014 08.09.2014 |
Problem solved at the following versions (IBM BugInfos) | |
Problem solved according to the fixlist(s) of the following version(s) | |
10.5.0.4 |