FastSort Manual

Using FastSort Commands
FastSort Manual429834-003
3-2
ASCENDING Command
For more information about using these commands, see Section 2, Sorting
Interactively. Appendix A, FastSort Syntax Summary contains a quick reference to the
command syntax.
ASCENDING Command
Use the ASCENDING command to sort or merge records so that the values of each
key field specified in the command are in smallest-to-largest order. ASCENDING and
DESCENDING commands can apply to the same sort run. If you apply both
commands to the same run, FastSort returns the values of the DESCENDING key
fields in largest-to-smallest order.
The ASCENDING command provides this information for a sort or merge run:
Location of one or more key fields for ordering the records
Length and order of the key fields
Type of data in each key field
You must specify at least one ASCENDING or DESCENDING command for each sort
or merge run. The DESCENDING Command on page 3-11 has the same parameters
as the ASCENDING command.
field
designates the location of a key field in the record. You can specify field in either
of two ways:
startcol : endcol
startcol FOR count
startcol
is an integer giving the beginning column number of a key field. The numbering
of record columns, or bytes, begins with 1.
endcol
is an integer giving the last column number of a key field.
count
is an integer giving the length, in bytes, of a key field.
type
describes the type of data in the key field. The default type is STRING. You can
specify type as:
ASC[ENDING] field [ type ] [ , field [ type ] ]...