EXTFLD(field_name)

The EXTFLD keyword is used to rename a subfield in an externally described data structure. Enter the external name of the subfield as the parameter to the EXTFLD keyword, and specify the name to be used in the program in the Name field (positions 7-21).

The external name can be either a simple name or a character literals. If a character literal is specified, the external name name name must be specified in the correct case. For example, if the external name is MYFIELD, the file-name parameter could be specified as a name in mixed case such as myField or myfield, but if specified as a literal it must be 'MYFIELD'.

If the name is not a valid simple RPG name, it must be specified as a literal. For example, to rename external field A.B, specify EXTFLD('A.B').

The keyword is optional. If not specified, the name extracted from the external definition is used as the data-structure subfield name.

If the PREFIX keyword is specified for the data structure, the prefix will not be applied to fields renamed with EXTFLD. Figure 121 shows an example of the EXTFLD keyword with the ALIAS keyword.



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