Controlling how records are added to a logical file with multiple formats

To add a record to a multiple-format logical file, you need to identify the member of the based-on physical file to which you want the record to be written.

If the application you are using does not allow you to specify a particular member within a format, each of the formats in the logical file needs to be associated with a single physical file member. If one or more of the based-on physical files contain more than one member, you need to use the DTAMBRS parameter, described in Defining logical file members, to associate a single member with each format. Finally, give each format in the multiple format logical file a unique name. If the multiple format logical file is defined in this way, then when you specify a format name on the add operation, you target a particular physical file member into which the record is added.

When you add records to a multiple-format logical file and your application program uses a file name instead of a record format name, you need to write a format selector program.