This structure is used to return additional table space statistics to an
application program.
Table 19. Fields in the SQLB-TBS-STATS Structure
Field Name | Data Type | Description |
---|---|---|
TOTALPAGES | INTEGER | Total operating system space occupied by the table space (in 4KB pages). For DMS, this is the sum of the container sizes (including overhead). For SMS, this is the sum of all file space used for the tables stored in this table space. This is the only piece of information returned for SMS table spaces; the other fields are set to this value or zero. |
USEABLEPAGES | INTEGER | For DMS, equal to TOTALPAGES minus (overhead plus partial extents). For SMS, equal to TOTALPAGES. |
USEDPAGES | INTEGER | For DMS, the total number of pages in use. For more information, see "Designing and Choosing Table Spaces" in the Administration Guide. For SMS, equal to TOTALPAGES. |
FREEPAGES | INTEGER | For DMS, equal to USEABLEPAGES minus USEDPAGES. For SMS, not applicable. |
HIGHWATERMARK | INTEGER | For DMS, the high water mark is the current "end" of the table space
address space. In other words, the page number of the first free extent
following the last allocated extent of a table space.
Note that this is not really a "high water mark", but rather a "current water mark", since the value can decrease. For SMS, this is not applicable. |
During a table space rebalance, the number of useable pages will include pages for the newly added container, but these new pages will not be reflected in the number of free pages until the rebalance is complete. When a table space rebalance is not taking place, the number of used pages plus the number of free pages will equal the number of useable pages.
Language Syntax
C Structure
/* File: sqlutil.h */ /* Structure: SQLB-TBS-STATS */ /* ... */ SQL_STRUCTURE SQLB_TBS_STATS { unsigned long totalPages; unsigned long useablePages; unsigned long usedPages; unsigned long freePages; unsigned long highWaterMark; }; /* ... */ |
COBOL Structure
* File: sqlutil.cbl 01 SQLB-TBS-STATS. 05 SQL-TOTAL-PAGES PIC 9(9) COMP-5. 05 SQL-USEABLE-PAGES PIC 9(9) COMP-5. 05 SQL-USED-PAGES PIC 9(9) COMP-5. 05 SQL-FREE-PAGES PIC 9(9) COMP-5. 05 SQL-HIGH-WATER-MARK PIC 9(9) COMP-5. * |