File Information Data Structure
A file information data structure (INFDS) can be defined for each file to make file exception/error and file feedback information available to the program or procedure.
The file information data structure, which must be unique for each file, must be defined in the same scope as the file. For global files, the INFDS must be defined in the main source section. For local files in a subprocedure, the INFDS must be defined in the Definition specifications of the subprocedure. Furthermore, the INFDS must be defined with the same storage type, automatic or static, as the file.
The INFDS for a file is used by all procedures using the file. If the file is passed as a parameter, the called program or procedure uses the same INFDS.
- File Feedback (length is 80)
- Open Feedback (length is 160)
- Input/Output Feedback (length is 126)
- Device Specific Feedback (length is variable)
- Get Attributes Feedback (length is variable)
The length of the INFDS depends on what fields you have declared in your INFDS. The minimum length of the INFDS is 80.