The @FSTAT statement can be used to output a list of files from the BS2000 catalog. It is possible to define the destination for the output. Optionally, it is also possible to output additional information about the files. The list is alphabetically sorted on the file names.
Operation | Operands | F mode, L mode |
@FSTAT | [{ file | svarex }] [[ TO] line [(inc)]] [{ SHORT | LONG [ISO4 ] }] |
file | Designates the files that are to be listed. The Here, the symbolic name ' If no file with the specified name is found, the message | ||||||||||||||||||||||||||||||||||||
svarex | The list of files for output can also be specified by means of a string variable | ||||||||||||||||||||||||||||||||||||
line | Line number as of which information is to be written to the current work file. If a line with a number greater than the previous highest line number is If | ||||||||||||||||||||||||||||||||||||
inc | Increment used to form the line numbers which follow | ||||||||||||||||||||||||||||||||||||
SHORT | One file is output per line. Only file names, together with the associated | ||||||||||||||||||||||||||||||||||||
LONG | Further catalog information is output in addition to the file names.
The list is alphabetically sorted on the file names. If the output is sent to | ||||||||||||||||||||||||||||||||||||
ISO4 | The creation date is output in the form |
If neither file
nor svarex
is specified then a list of all the files under the user's own ID is output.
If neither SHORT
nor LONG
is specified then only the file names are output (one per line). If the file specification in file
or svarex
contains a catalog ID, the file names are output with the catalog ID and user ID.
Otherwise, the file names are output in the same form as they are specified in the statement.
Partially qualified file names with a user ID form an exception here. In this case, @FSTAT outputs a list of file names without catalog IDs or user IDs for reasons of compatibility.
Output to SYSOUT
or SYSLST
is sent in the character set that has been defined for these system files. If the output is written to a work file then it is sent in the work file's character set. If the work file is empty and has the character set *NONE
then the character set EDF041
is used. Characters that cannot be displayed in the target character set are always replaced by blanks.
Caution
In the case of large files, the fields for the reserved and used size for output in LONG
mode may not be sufficient. In this case, nothing is output here. To ensure complete output in these cases, only the @SHOW command (format 1) should be used.