SYSFILRC Automatic Macro Variable

Contains the return code from the last FILENAME statement.
Type: Automatic macro variable (read and write)

Details

SYSFILRC checks whether the file or storage location referenced by the last FILENAME statement exists. You can use SYSFILRC to confirm that a file or location is allocated before attempting to access an external file.
The following are values for SYSFILRC:
SYSFILRC Values and Descriptions
Value
Description
0
The last FILENAME statement executed correctly.
≠0
The last FILENAME statement did not execute correctly.