HP Data Entry and Forms Management System (VPLUS) Reference Manual (32209-90024)

186 Chapter5
Reformatting Specifications
Relation of Forms to Output Records
records starting with the reformat identifier must exactly match the sequence of forms.
Output Record Definition
The output record definition determines how information from batch file records is stored
in the output file. Any field in the batch file that is to be written to an output record must
be uniquely identified. The sequence of the output field names in the output record
definition determines the order in which fields are written to the output record. Fields
from the batch file may thus be reordered, or repeated, or omitted from the output record.
Constants, in the form of literals, system constants, or the numeric equivalent of USASCII
characters, can be interspersed freely between fields or portions of fields in the output
record definition.
The output record definition also determines where each output record begins. The
designer can mark one or more fields (or constants) as the starting point of a record. If no
field is so marked in an output record definition, then the first field in the definition is
appended to the last field in the previous definition as part of the same record. Thus a
batch record can be divided into several output records, or be made part of a larger record.
Note that you can specify a fixed record length, or a maximum variable record length, for
all output records through the Globals Menu. REFSPEC does not allow the designer to
specify a record in any one output record definition that is longer than this maximum
length; however, it does not check the length of a record formed from several output record
definitions. Some rules to remember:
A unique output field name must be assigned to any batch field to be written to the
output file. (Usually, the input field name is unique and can be used as the output field
name.)
Batch fields are written to the output file in order of the output field names.
Only those fields specified in an output record definition are written to the output file.
A particular batch field can be specified many times in a single output record definition
as long as each occurrence is given a unique output field name.
A start-of-record marker in an output record definition determines the start of an
output record.
A start-of-record marker can be associated with any field or constant in an output
record definition.
If no start-of-record marker is included in an output record definition, the first field of
this definition follows the last field of the preceding definition when it is written to the
output file.