RPG/400 Help

Position 16 (File Designation)

Entry
Explanation
Blank
Output file
P
Primary file
S
Secondary file
R
Record address file
T
Array or table file
F
Full procedural file

Primary File

When several files are processed by cycle processing, one must be designated as the primary file. In multifile processing, processing of the primary file takes precedence. Only one primary file is allowed per program.

Secondary File

When more than one file is used during cycle-controlled programming, secondary files are input files. The processing of secondary files is determined by the order in which they are specified in the file-description specifications and on the rules of multifile logic.

Record Address File

A record-address file is a sequentially organized file used to select records from another file. Only one file in a program can be specified as a record-address file. This file is described on the file-description and extension specifications and not on the input specifications. The file processed by the record-address file must also be specified on the extension specifications and must be a primary, secondary, or full procedural file.

You cannot specify a record-address file for the device SPECIAL. You cannot specify an externally described file as a record-address file; however, you can use a record-address file to process a program described file or an externally described file.

A record-address file that contains relative-record numbers must also have a T specified in position 32 and an F in position 19.

Array or Table File

Array and table files specified by a T in position 16 are loaded at program initialization time. The array or table file can be input or combined. Leave this entry blank for array or table output files. You cannot specify SPECIAL as the device for array and table input files. You cannot specify an externally described file as an array or table file.

If T is specified in position 16, you can specify C in position 15 for a DISK or SEQ file. This C allows an array or table file to be read from or written to the same file (an array or table replacement file). The To and From file names on the extension specifications must specify this file name.

Full Procedural File

This entry is used when the input is controlled by calculation operations. File operation codes such as CHAIN or READ are used to do input functions.


[ Top of Page | Previous Page | Next Page | Table of Contents ]