TABLEX command
Summary
- Privileges
- File manager
- Function
- Displays information about memory use in Table X of a Model 204 file
Syntax
TABLEX [LIST] [RECORD LENGTH] [PAGE pagenumber] [PAGES pagenumber1 TO pagenumber2]
Where:
The following options display memory use in Table X. A TABLEX command accepts only one option per command, unless the LIST option is specified, which can be followed by the RECORD LENGTH option.
Option |
Displays... |
---|---|
LIST |
One line for each Table X page scanned, from the lowest to the highest page. |
RECORD LENGTH |
RECORD LENGTH can be abbreviated as RECLEN. If XSIZE=0, RECLEN yields the message: M204.2768:FILE filename HAS NO TABLE X PAGES If XSIZE>0, RECLEN yields average length of an individual record in Table X. |
OVERFLOW |
Table X averages for the overflow area of a sorted file. |
MASTER |
Table X averages for the master area of a sorted file. |
pagenumber, pagenumber1, and pagenumber2 |
Specific pages in Table X. |
PAGE |
Table X averages for the specified file page. |
PAGES |
Table X averages for page pagenumber1 through page pagenumber2. |
Examples
TABLEX command output
TABLEX 507 AVG. FREE SPACE PER PAGE 2 AVG. FREE SLOTS PER PAGE 68 NUMBER OF PAGES PROCESSED 16 XRECPPG - TABLE X RECORDS PER PAGE 17 XRESERVE - TABLE X RESERVED SPACE PER PAGE
Usage notes
You can issue a TABLEX command only in file context: that is, the current default must be a file, not a group.
TABLEX command output can be routed to a USE data set.
If you specify a TABLEX RECLEN x command, where x is something other than end-of-line, the following error is issued.
M204.0643: AN OPERAND IS INVALID OR MISSING
Using the TABLEX command without any option provides only the averages (shown in the previous example) over Table X active pages.
Using the LIST option
To get the exact amounts of free space and free slots on each active page, you must use the LIST option. This option produces a printed line for each Table X page scanned, starting with the lowest active page and ending with the highest one. The output of the LIST option, which precedes the averages shown above, is displayed in the following format:
PAGE NO. FREE SPACE FREE SLOTS nnn nnn nnn . . . . . . . . .
If the current file is a sorted one, each line includes an indication of the type of page that the line describes. For example, if page number 5 is an overflow page, the output might be:
PAGE NO. FREE SPACE FREE SLOTS 5 200 28 OVERFLOW
Limiting the range of pages scanned
You can limit the range of Table X pages to be scanned in the following ways:
-
Specify the PAGE or PAGES option to select a single page or a range of pages.
The following command causes a scan of five pages, if they fall in the range of active pages. If any of the selected pages is inactive, an error message is issued and the command is ignored. Page numbers are specified in decimal and cannot be negative. For example:
TABLEX PAGES 0 TO 4
-
Limit the range of pages scanned. This way applies only to sorted files. Use the options OVERFLOW or MASTER. In either case, the scan is done only over the specified pages.
Using the RECORD LENGTH option
The RECORD LENGTH option provides the average length of an individual (extension) record in Table X. An individual Table X record includes all the extensions for a particular Table B base record. No Table B information is included.
The average record length is exact unless DELETE RECORDS or IFDSET is used in the file. If DELETE RECORDS or IFDSET is used, the record length computed is too big, because space from the deleted records is never released.
The RECORD LENGTH option is available only when all of Table X is scanned. Or, to state it another way, RECLEN option does not work with either the PAGE n or the PAGES n1 TO n2 option.