OPTIONS - options for the BSORT command.
Options:
(+|-)ASCending (+) (+|-)DEScending (-)
(+|-)Duplicate (+) (+|-)Raw (+)
(+|-)Unique (+|-)Verbose (-)
Error=code IgnoreLeading=string
Key=key-string KeyFile=file
MediaCode=code Memorysize=number
RecordSize=words RejectFile=file
SKip=string STop=string
Workfiles=number (1)
- +ASCending
- indicates that the sorted output should be in ascending
order. This is the default.
- +DEScending
- indicates that the sorted output should be in descending
order.
- -Duplicate
- indicates that if there are several records with the same
contents in their key fields, all but one of these should
be discarded from the output. For example, if a file of
students is being sorted by name and student number, the
output will only contain one record with a given name and
number; records which have the same name and number as a
previous record will be deleted from the output. The
default is +Duplicate, which leaves duplicate records
intact.
- -Raw
- indicates that input records should be converted to ASCII
as they are read in. Normally, input is just stored
"as is". If the input is already in ASCII,
there is almost no difference between +Raw and -Raw,
except that +Raw records will include the standard RCW,
etc.
- +Unique
- indicates that if there are several records with the same
contents in their key fields, all of them should be
discarded from the output. For example, if a file of
students is being sorted by name and student number, the
output will discard any collection of records that have
the same name and number. Thus, +Unique discards all
duplicates, while -Duplicate discards all but one copy of
each duplicate.
- -Unique
- indicates that the only records that should appear in the
output are ones whose key fields duplicate other records.
Thus, all records with unique key fields are discarded.
If both -Unique and -Duplicate are specified, BSORT
discards all records with unique key fields (because of
-Unique), then discards all but one copy of each
duplicate record.
- +Verbose
- prints statistics about the sort process after it is
finished. The default is -Verbose.
- Error=code
- indicates the action that should be taken for records
found to be erroneous (e.g. the record was supposed to
have a key beginning at character 20, but the record is
only 10 characters long). The following codes are
recognized.
- Stop
- stop processing if an erroneous record is found.
- Report
- print a message on the terminal whenever an
erroneous record is found. This message notes the
source of the record if there is more than one
input file.
- Ignore
- ignore the fact that the record is erroneous.
This is the default. The record will be included
in the sorting process as if it was not in error
-- for more details about this, see the section
below on "Error Handling".
- First
- cause all records with erroneous keys to appear
before anything else in the sorted output. Thus
the erroneous records will be sorted as well as
possible amongst themselves, then placed at the
beginning of the output.
- Last
- cause all records with erroneous keys to appear
after everything else in the sorted output. Thus
the erroneous records will be sorted as well as
possible amongst themselves, then placed at the
end of the output.
- IgnoreLeading=string
- specifies a default set of characters to be ignored when
parsing records to find key-fields. By default,
"string" is " *t*n" so that leading
blanks, tabs, and new-lines are ignored. For further
information, see the description of key-fields below.
- Key=key-string
- specifies a key-string which describes a key to be used
in the sorting. Possible formats for key-strings are
described below. If there is no "Key="
specified for a sort, the entire record will be used as a
key; otherwise, there should be one "Key="
specification for every key used in the sorting process.
For example, if a file of students is to be sorted by
student name, and student number within name, there must
be a "Key=" describing where the name is found
in each record and a second "Key=" describing
where the student number is found. The order in which
"Key=" options appear on the command line gives
the order of importance of the keys.
- KeyFile=file
- specifies a file containing key-strings. Each line of the
file contains a separate key-string. These key-strings
are the same as those given with "Key=", but
without enclosing quotes. A "Keyfile=" may
appear anywhere on the command line that a
"Key=" can. The order of key-strings in the
file gives the order of importance of the keys described.
- MediaCode=code
- specifies the media code to be used when writing the
output into "outfile". MediaCode automatically
implies the -Raw option. The default is Media-6 ASCII.
- Memorysize=number
- specifies the maximum amount of memory BSORT may use. The
default is 30(K). BSORT may run faster if more memory is
specified, but this depends on how busy the system is.
- RecordSize=words
- specifies the maximum length of any input record, in
words. The default is 300 words. "Recordsize"
may not be greater than 7000 (words).
- RejectFile=file
- specifies a file into which BSORT will write erroneous
records. If "file" is omitted (i.e. you just
type "rf="), these erroneous records will
simply be discarded.
- SKip=string
- specifies a default set of characters to be skipped when
beginning to parse records to find key-fields. By
default, "string" is " *t*n" (a
blank, a tab, and a new-line). For further information,
see the description of key-fields below.
- STop=string
- specifies a default set of characters that mark the end
of a key-field when parsing records to find key-fields.
By default, "string" is " *t*n" (a
blank, a tab, and a new-line).
- Workfiles=number
- specifies the number of work files that BSORT is to use.
In TSS the temp files are called fc*s1, fc*s2 ... In
batch file codes S1, S2 ... are used. This option is only
needed for large sorts where the amount of data causes
BSORT to exceed what will fit in a single work file.
See Also:
- expl bsort
- full description of BSORT
- expl bsort batch
- using BSORT in batch
- expl bsort collate
- collating orders
- expl bsort errors
- error handling
- expl bsort examples
- examples of BSORT operations
- expl bsort keyopt
- key options
- expl bsort notes
- miscellaneous notes
- expl bsort position
- key position descriptors
Copyright © 1996, Thinkage Ltd.