Have you ever wanted to see a (near) real-time view of how much data is being read from or written to your tables? How about your temporary tables? The db2top Tables screen does all of this and more.
In today’s post, you will learn how to:
- identify which tables are most heavily being impacted by reads or by writes
- identify which tables have the greatest storage requirements
- monitor the progress of any tables being reorganized and see the impact of compression
- identify the users and applications of temporary tables
You launch the db2top Tables screen by holding down the Shift key and pressing the ‘T’ key. The table information is presented, not surprisingly, in a table. It is shown below for a screen that is 80 columns wide:
We will examine the table one screen’s worth of columns at a time:
Column Name | Definition |
---|---|
Table Name | The fully qualified name of the table. For permanent tables, it takes the following form: table_schema.table_name and is truncated to 40 characters. On systems using the Data Partitioning Feature (DPF), in which each row is a table partition instead of a table, it takes the following form: table_schema.table_name[data_partition_id] and is truncated to 40 characters. |
|
|
|
|
Data Pages | The number of disk pages consumed by a table (data_object_pages). This size represents the base table size only. |
Column Name | Definition |
---|---|
Index Pages | The number of disk pages consumed by all indexes defined on a table (index_object_pages). |
Page Reorgs |
|
|
|
XDA_Page Reorgs |
|
Table Type | The type of table (table_type). It can have one of the following values:
|
Reorg% Progress | If this table is in the process of being reorganized, this shows the percentage of reorganization work that has been completed (reorg_current_counter / reorg_max_counter × 100%). Shows a "-" if there is no reorganization of this table in progress. |
|
|
Column Name | Definition |
---|---|
|
|
Tablespace Name | The name of the table space of this table (tablespace_name). If no table space can be found for this table, it shows “tbspid x” where x is the table space ID (tablespace_id). |
Table Size | The size of the table in some multiple of bytes, such as KB, MB, etc.
(data_object_pages + index_object_pages) × tablespace_page_size When tablespace_page_size cannot be determined for the table’s table space, 4096 is used. |
Appl Handle | Application handle extracted from the table_schema for temporary table spaces. Otherwise, it shows “-”. |
DB User | Database user ID extracted from the table_schema for temporary table spaces. Otherwise, it shows “N/A”. |
Recent RowAcc[1 to 30] | The number of rows read or written for this table over the specified window of time. A sliding window is used to measure only the last x samples, where x is a number between 1 and 30 that the user can control using the ‘+’ and ‘-‘ keys. rows_read + rows_written |
In part 2, we will see all the additional information that appears when you increase the screen width past 140 columns.