In order to buffer and sort the set and owner statistics, BSTATUS requires two work files. These work files are set up automatically on public disk by BSTATUS under the user ID under which it was started. The default link names of these files are SCRTCH1 and SORTWK.
SCRTCH1
BSTATUS requires this file as temporary storage for the set statistics when the output of set and owner statistics is requested.
SORTWK
Requires the SORT used by BSTATUS for sorting internal evaluation records (see manual “SORT (BS2000)”.
If the work files are to be created explicitly, they must be assigned the following attributes:
Work-file-1
File link name SCRTCH1
Access method = SAM
The data population for buffering can be calculated using the following formula:
132 * (no. of sets + no. of keys) Bytes
no. of sets
Number of sets in the subschema to be checked
no. of keys
Number of keys in the subschema to be checked
The primary allocation for Work-file-1 should be based on the data population that is to be buffered. There should always be an appropriate secondary allocation in case the storage space proves to be insufficient.
Work-file-2
SORT needs Work-file-2 if there is not enough virtual memory for pre-sorting. The primary allocation should be based on the data population that is to be sorted while taking account of the safety factor recommended by SORT (see the discussion of work files in the manual “SORT (BS2000)”). There should always be an appropriate secondary allocation in case it is necessary to extend the storage space.
File link name SORTWK
Access method=PAM
The data population for sorting can be calculated using the formula:
16 * no. of sort records Bytes
no. of sort records
Number of records to be processed in the table statistics.
If the two work files are not created explicitly, BSTATUS generates them automatically with the following names and sizes:
UTI.SAMWORK.tsn.time-stamp.nnnn | (33,33) |
UTI.tsn.SORTWK | (120,120) |
tsn
task sequence number of the current task.
time-stamp
date and time (yyyymmddhhmmss) on which the file was created.
nnnn
four-digit sequential number.
If execution terminates normally, any work files created by BSTATUS and their file link names are deleted. Any work files that you have set up explicitly are not deleted and their file link names are not released.