Use Flag (UF) Fields

Each field in a file record in working storage has a corresponding a use flag, defined in a data structure. To write to a field, its associated use flag must be nonzero.

Field Description
P<Prefix><RPGFieldName>-UF (Lawson RPG)

If two or more use flags have the same nonzero value, S@CSVWRITE@<Prefix> writes the fields in file-record order. If the nonzero values are unique, S@CSVWRITE@<Prefix> writes the fields using the order set by the values in the use flag fields. For more information, see S@CSVWRITE@

On input files (where Usage is defined as Input or Input/Output), the value of the use flag determines how a record is read into working storage. If the flag is set to not used, the record is initialized. For more information, see S@CSVREAD@

To set all use flags at once, use S@CSVALLUS@