The SORT control statement defines the sort sequence by which the input data is sorted for the report. Only one SORT control statement is allowed. This control statement is optional. However, it must be submitted if the NEWPAGE control statement in the REPORT-SECTION is used. If the SORT control statement is not submitted, the input file is sorted into ascending sequence by volume serial number. The format for the SORT control statement is:
SORT [sequence-]keyword... [sequence-]keyword
Control Statement Definition
Identifies the control statement. It must be followed by a space.
Defines the sequence order by which the data is sorted. Valid sequences are:
Ascending order (default)
Descending order
The sequence must be separated from the following keyword by a dash (-). If sequence is not specified, the default sequence is A (ascending order).
Defines the field to be sorted.
Multiple SORT fields (sequence-keyword) may be specified by separating the expressions by a space. The first keyword specified is the major sort field. There is a limit of six sort fields.
|
Copyright © 2013 CA Technologies.
All rights reserved.
|
|