Runstats Tablespace
Go Up to Available object actions by DBMS
The Runstats Tablespace Wizard gathers statistics on tablespaces, indexes, and columns. This information is recorded in the DB2 catalog and uses it to select access paths to data during the bind process. The wizard lets you evaluate database design and helps you decide to reorganize tablespaces or indexes.
Platform Availability
To Perform a RunStats Operation Against a Tablespace
- On the Datasource Explorer, expand the Tablespaces node or in the Datasource Navigator expand that node.
- Objects of the selected type are displayed.
- Right-click the target tablespace and select RunStats Tablespace from the context menu.
- The RunStats Tablespace Utility wizard opens.
- Use the following table as a guide to understanding and modifying settings in the wizard:
Step | Settings and tasks | |
---|---|---|
Preliminary options |
Database Name |
Lets you select a database. |
Tablespace Name |
Lets you select a tablespace. | |
Partition Number |
Lets you specify on which the command needs to be run. | |
Do you want to runstats on all tables in this tablespace? |
Default is Yes. | |
Do you want to runstats on all indexes in this tablespace? |
Default is Yes. | |
Table sample and key card details (Panel is displays only if you selected Yes to either of the all indexes... or all tables... options on the first panel) |
Table Sample |
Lets you type a table sample. Default is 25. You can enter any value between 1 and 100. |
KeyCard |
Collects all of the distinct values in all of the 1 to n key column combinations for the specified indexes. n is the number of columns in the index. | |
Add |
Opens the Add Frequent Item Dialog Box | |
Delete |
Deletes selected item(s.) | |
Table selection (Panel is displays only if you selected No to the all tables... options on the first panel) |
Select Tables |
Lets you select the tables in the table that runstats will be run on. The Sample column is blank initially for each row. It is editable with values between 1 - 100. The Indicator column is blank initially for each new row that is added. However if you set the custom columns for a row (via set properties button), this column shows an asterisk (*). |
Add |
Opens the Table Selector Dialog Box. | |
Delete |
Deletes the selected table(s.) | |
Set Properties |
Lets you customize the selection of columns in the selected table(s.) | |
Index selection (Panel is displays only if you selected No to the all indexes... options on the first panel) |
Select Indexes |
Lets you select index(es) for the runstats operation. |
Add |
Opens the Select Column for Table Dialog Box. | |
Delete |
Deletes selected index(es). | |
Set Properties |
Opens the Set Correlation Option Dialog Box. | |
Runstats options |
Access level while RUNSTATS is running |
Lets you select an access level, either Readonly or Change. |
Do you want to output message to SYSPRINT? |
Lets you specify to output message to SYSPRINT. | |
Do you want to force aggregation or rollup processing to be done even though some parts do not contain data? |
Lets you specify to process with forced aggregation, gathered into a mass, or rollup. | |
Statistics |
Update Statistics |
Lets you update the catalog statistics. |
History Statistics |
Lets you update the history statistics. |
- 4. When ready, click Finish.
Select Column for Table Dialog Box
The table below describes the options and functionality on the Select Column for Table dialog:
Option | Description |
---|---|
Column Name |
Displays the column name. |
Included |
Select to include column. |
Select All |
Click to select all columns. |
Unselect All |
Click to deselect all columns. |
Table Selector Dialog Box
The table below describes the options and functionality on the panel of the Table Selector dialog
Option | Description |
---|---|
Tablespace Like |
Displays the tablespace. |
Table Creator |
Displays the table(s) creator of the tablespace that was selected on Panel 2. |
Table Name |
Displays the table(s) of the tablespace that was selected on Panel 2. |
All Columns |
Selects all columns. |
Table Selector |
Lets you select one or more rows per table, up to 10. |
Query |
Repopulates Table Selector based on the tablespace query. |
Select All |
Selects all rows in Table Selector. |
Unselect All |
Unselects all rows in Table Selector. |
Add |
Click to add the table to the wizard. |
Index Selector Dialog Box
The table below describes the options and functionality on the panel of the Index Selector dialog
Option | Description |
---|---|
Index Creator |
Displays the index(es) creator of the tablespace that was selected on Panel 2. |
Index |
Displays the index(es) of the tablespace that was selected on Panel 2. |
Index Selector |
Lets you select one or more rows in this list. |
Query |
Repopulates Index Selector based on the tablespace query. |
Select All |
Selects all rows in Index Selector. |
Unselect All |
Unselects all rows in Index Selector. |
Add |
Click to add the index to the wizard. |