Updating DB2 for OS/390 table space statistics

Use the DB2 for OS/390 Runstats Data Warehouse Center program to gather summary information about the characteristics of data in table spaces, indexes and partitions. The output is recorded in the DB2 for OS/390 catalog tables. DB2 uses this information to select access paths to data during the bind process. The information is available to the database administrator for evaluating database design and to aid in determining when table spaces or indexes must be reorganized.

../byb.gif Authorities and privileges

To update table space statistics:

  1. Open the step notebook.

  2. Specify information for your step:

    .  
     

  3. On the Parameters page, click one of the Share level radio buttons to specify the access that other programs can use on the table space while you are gathering statistics:

  4. Click one of the Report statistics radio buttons to specify if a set of messages is generated to report the collected statistics. Specify Yes if you want the set of messages output to the SYSPRINT data set. Specify No to have no messages sent to SYSPRINT. This is the default.

  5. Click one of the Update options on catalog tables radio buttons to specify whether the collected statistics are inserted into the DB2 for OS/390 catalog tables:

    Access path and space statistics

    The result of gathering the statistics updates all the statistics in the DB2 catalog.

    Access path statistics only

    The result of gathering the statistics updates only the catalog table columns used for access path selection.

    Space statistics only

    The result of gathering the statistics updates only the catalog table columns that help a database administrator assess the status of a particular table space or index.

    Do not update catalog tables

    The result of gathering the statistics does not update any catalog statistics. Available only when the Report Statistics radio button is YES.

  6. In the Percent rows sampled for non-index columns field, specify a percentage of rows to sample when collecting non-indexed column statistics. Valid values are 1 to 100 percent. The default is 25 percent. Do not use this field if your table space is a LOB table space.

  7. The columns in a table for which you are gathering statistics are listed in the Available columns list. Click on a column and click the > push button to move a column from the Available columns list to the Selected columns list. You can move all the columns in the table by clicking the >> push button. The reverse actions, to remove single or all columns is the < or << push buttons. This removes columns from the Selected columns list back to the Available columns list. All columns in the Selected columns list are the columns on which statistics are gathered. You can select a maximum of 10 columns with one table space statistics operation.

  8. On the Processing Options page, in the Agent Site list, select an agent site where you want your step to run. The selections in this list are agent sites that are common to the source tables, the target table, and the transformer or program that you are defining.

  9. If you want to have the option to to run your step at any time, select the Run on demand checkbox. Your step must be in test or production mode before you can run it.

  10. Optional: Select the Populate externally check box if the step is populated externally, meaning that it is invoked in some way other than by the Data Warehouse Center. The step does not have to have any other means of running in the Data Warehouse Center in order to change the mode to production.

    If Populate externally is not selected, then the step must either have a schedule, be linked to a transient table that is input to another step, or be started by another program in order to change the mode to production.

  11. In the Retry area, specify how many times you want the step to run again if it needs to be retried and the amount of time that you want to pass before the next run of the step.

  12. Click OK to save your changes and close the step notebook.

Related information

Moving and transforming data

Population type descriptions

List of steps and step subtypes

Data Warehouse Center concepts