Using DB2’s ADMIN_MOVE_TABLE to Move Tables from One Tablespace to Another

You may also like...

7 Responses

  1. Nice article Ember and thanks for sharing some great example. Just wanted to add couple of points to the above, as many of us use this ADMIN table option unknowingly.

    This utility is indeed useful in Db2 V10.5 aka BLU as well. While you are required to convert a Row Organized table into a Column Organized table in BLU, we use the db2convert utility in 10.5 and that tool itself calls ADMIN_MOVE_TABLE in the background.

  2. raghu says:

    Hi Ember, nice reference, this helped me resolve an issue quickly.

    Found out that SQL may need correction here.

    TYPENAME like ‘%LOB’

    Cheers!!

  3. Chaitanya says:

    When we perform Rename activity on a table that has 10000 rows.in DB2
    1. Do we have to manually exp/imp data to the newly renamed table?or the data gets reflected automatically in the newly renamed table
    2.Do we have to manually create the structure of new table before renaming activity ? or not required.
    3. Is Reorg/runstats required post renaming activity..

    Gurus, please answer my questions.
    Thanks in Advance..

    • Ember Crooks says:

      All the rename command does is change the name of the table. The structure of the table is not changed or even copied, only the name of the table, which is not included in any of the table-related structures. You cannot change the schema the table is. You may want to consider renaming indexes, which may include some part of the table name depending on your naming standards. All authorizations are automatically updated. I would probably do runstats to be safe, but I don’t believe it would be required.

  4. Chaitanya says:

    In addition to my previous questions.. what are all the restrictions that we have for Renaming table

Leave a Reply

Your email address will not be published. Required fields are marked *