IBM Support

IT26760: ADMIN_MOVE_TABLE MIGHT FAIL WITH SQL0668N WHEN RETRYING COPY OPERATION ON COLUMNAR TARGET TABLE

Subscribe to this APAR

By subscribing, you receive periodic emails alerting you to the status of the APAR, along with a link to the fix after it becomes available. You can track this item individually or track all items by product.

Notify me when this APAR changes.

Notify me when an APAR for this component changes.

 

APAR status

  • Closed as program error.

Error description

  • If admin_move_table is called and COPY phase fails, the target
    table might be left in LOAD PENDING status.
    After the root cause (e.g. lack of diskspace, utill_heap_sz,
    etc) for getting into the LOAD PENDING status has been removed,
    ADMIN_MOVE_TABLE can be restarted with the COPY operation.
    
    In case of a columnar target table, the restarted AMT COPY
    operation might fail with SQL0668 while truncating the target
    table. This is because the LOAD PENDING status is not
    automatically fixed by AMT like in other similar situations.
    This fix implements an automatic LOAD TERMINATE command and
    retries the truncation of the target table, if such a situation
    happens.
    
    Alternatively, the user can manually issue the LOAD TERMINATE
    command if such a situation happens.
    e.g.:
    
    CALL
    SYSPROC.ADMIN_MOVE_TABLE('<SCHEMA>,'<SOURCE_TAB>','<TARGET_TAB>'
    ,'ALLOW_READ_ACCESS','INIT')
    CALL
    SYSPROC.ADMIN_MOVE_TABLE('<SCHEMA>,'<SOURCE_TAB>','<TARGET_TAB>'
    ,'ALLOW_READ_ACCESS','COPY')
    
    *** The ADMIN_MOVE_TABLE copy step is interrupted and fails when
    it is repeated ***
    
    CALL
    SYSPROC.ADMIN_MOVE_TABLE('<SCHEMA>,'<SOURCE_TAB>','<TARGET_TAB>'
    ,'ALLOW_READ_ACCESS','COPY')
    SQL0668N  Operation not allowed for reason code "3" on table
    "<SCHEMA>.<TARGET_TAB>".  SQLSTATE=57016
    
    *** Manually issue a LOAD TERMINATE command on the target table
    ***
    
    LOAD FROM /dev/null of del TERMINATE INTO
    "<SCHEMA>"."<TARGET_TABLE_NAME>"
    
    *** The ADMIN_MOVE_TABLE copy step can be repeated ***
    
    CALL
    SYSPROC.ADMIN_MOVE_TABLE('<SCHEMA>,'<SOURCE_TAB>','<TARGET_TAB>'
    ,'ALLOW_READ_ACCESS','COPY')
    

Local fix

  • Manually issue a LOAD TERMINATE command on the target table if
    such a situation happens. Refer to the error description to see
    an example.
    

Problem summary

  • ****************************************************************
    * USERS AFFECTED:                                              *
    * ALL                                                          *
    ****************************************************************
    * PROBLEM DESCRIPTION:                                         *
    * See Error Description                                        *
    ****************************************************************
    * RECOMMENDATION:                                              *
    * Upgrade to Db2 11.1 Mod 4 Fixpack 5 or higher                *
    ****************************************************************
    

Problem conclusion

  • First fixed in Db2 11.1 Mod 4 Fixpack 5
    

Temporary fix

Comments

APAR Information

  • APAR number

    IT26760

  • Reported component name

    DB2 FOR LUW

  • Reported component ID

    DB2FORLUW

  • Reported release

    B10

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt / Xsystem

  • Submitted date

    2018-10-26

  • Closed date

    2020-01-16

  • Last modified date

    2020-01-16

  • APAR is sysrouted FROM one or more of the following:

  • APAR is sysrouted TO one or more of the following:

Fix information

  • Fixed component name

    DB2 FOR LUW

  • Fixed component ID

    DB2FORLUW

Applicable component levels

  • RB10 PSN

       UP

[{"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Product":{"code":"SSEPGG","label":"Db2 for Linux, UNIX and Windows"},"Component":"","ARM Category":[],"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"11.1","Edition":"","Line of Business":{"code":"LOB10","label":"Data and AI"}}]

Document Information

Modified date:
16 January 2020