Description
Tests linear hash tables, and stores statistical information about data distribution and space utilization for a table or tables. Verify_LH also diagnoses group format errors (GFEs).
Note: By default, the index table (the ! file) and the dictionary (DICT.filename) associated with the table are verified, along with the data portion of the file. If you only wish to verify the data portion only, prefix tablelist with DATA., as in DATA.orders.
Syntax
Verify_LH (volumelist, tablelist, ignoreflag, keepflag, detailflag)
Parameters
Verify_LH accepts arguments for the following parameters.
Parameter | Description |
---|---|
volumelist | Contains the operating system path and drive identifier for each volume to test or the key of a volume definition row in the SYSPTRS table. If null, then tablelist is tested. If volumelist and tablelist are null, the default volume, specified using the system stored procedure Set_Env, is used. Note: As of Version 4.1.3, volumelist can reference a UNC style location, such as a location on another computer (for example \\server\share\revdata, referring to folder \share\revdata on the computer \\server). |
Tablelist | A table or list of tables in a specific volume to test. You can test the data, dictionary, and index tables separately by entering the appropriate table name. Multiple tables are delimited by @FM. If volumelist and tablelist are null, the default volume, specified using the stored procedure Set_Env, is used. |
ignoreflag | Set ignoreflag to true (1), to continue testing all tables specified, if an error is encountered during testing. |
keepflag | If true (1), the data in the output tables SYSLHVERIFY and SYSLHGROUP is not cleared. By default, the tables are cleared if this flag is not set. |
detailflag | If true (1), detailed statistical information about each group in the table or tables tested is saved in the SYSLHGROUP table. |
Output
For each table tested by Verify_LH, a row is stored in SYSLHVERIFY. The fields are as follows:
Field Number | Description |
---|---|
0 | Key, in the format DateTimeVerified*Application_Name*TableName |
1 | Date and Time verified, in internal (ICONV) format |
2 | Group |
3 | Frame size, in bytes |
4 | LK_size, in bytes |
5 | OV_size, in bytes |
6 | Modulo |
7 | Sizelock (0 = off, 1 = on) |
8 | Frame for free space |
9 | Unused free space |
10 | Number of rows |
11 | Row count |
12 | Rows per group |
13 | Average row length |
14 | Primary frame row factor (percent of primary frames used) |
15 | Overall load factor (percent of all frames used) |
16 | Average disk I/O |
17 | Standard disk I/O |
18 | Average overflow for group |
19 | Standard overflow for group |
21 | Load factor |
If detailflag = 1, a row in SYSLHGROUP per group per table verified is generated, with the following fields:
Field Number | Description |
---|---|
0*1 | Date and Time verified, in internal (ICONV) format |
0*2 | Application Name |
0*3 | Table Name |
0*4 | Group Number |
1 | Number of Frames |
2 | Number of Rows |
4 | Average disk I/Os |
See also
Example
/* Verifies the structure of the ORDERS table (including the bang file and dictionary file) and the data portion of the INVOICES table, in the volume DATAVOL. If errors are found in ORDERS, testing continues on DATA.INVOICES. SYSLHVERIFY and SYSLHGROUP are not cleared. Detailed group information is saved in the SYSLHGROUP table. */ declare subroutine verify_lh declare function get_status TableList = "ORDERS":@FM:"DATA.INVOICES" Verify_LH("DATAVOL", TableList, 1, 1, 1) If Get_Status(ErrCodes) Then GoSub ErrorHandling End return 0 ErrorHandling: * process errors here return