Manually reorganizing tables in shadow table environments

To allow space reclamation, you must reorganize your shadow tables.

Before you begin

Ensure that you have the required authorization for the REORG TABLE command. For information, see REORG TABLE command.

About this task

Enabling automatic reorganization works best for shadow tables. For column-organized tables, it is recommended that you enable automatic reorganization. If automatic reorganization is not enabled, then the REORG command with the RECLAIM EXTENTS option must be run to reorganize shadow tables.

Procedure

To reorganize a shadow table manually:

  1. Connect to the database that contains the table that you want to reorganize.
  2. Reorganize the shadow table by issuing the REORG TABLE command with the RECLAIM EXTENTS option.
    The following example shows how to reorganize the table DTW.TRADE_SHADOW:
    REORG TABLE DTW.TRADE_SHADOW RECLAIM EXTENTS

What to do next

After you reorganize a shadow table, collect statistics on that table so that the optimizer has the most accurate data for evaluating query access plans.