COLLATE - collating orders for the BSORT command.

Collating Orders:

+AscII                   +BINary
+BinaryFloating          +BinarySigned
+Caseless                +DATe
+DECimal                 +DICtionary
+FloatingPoint           +FloatingPoint4bit
+FloatingPoint9bit       +HEXadecimal
+LeadingSigned4bit       +LeadingSigned9bit
+Location                +NotSigned4bit
+NotSigned9bit           +Numeric
+OCTal                   +ONLy
+TrailingSigned4bit      +TrailingSigned9bit
+Width
+AscII
indicates that the key should be sorted according to the ASCII collating sequence. This is the default. In fact, +AscII treats the input as if it consists of unsigned binary integers. If the input is in BCD and +Raw is in effect, +AscII will sort the BCD input in standard BCD collating order. Remember that if you do sort BCD data this way, you may need to express the length of the sort key in 6 bit BCD characters characters rather than the default 9 bit bytes.
+Caseless
indicates that the case of letters in the key should be ignored. Thus all the keys beginning with "A" or "a" will be grouped together, all those with "B" or "b", and so on. This option may only be used with ASCII input. If two keys compare equal, they are compared again as raw text (so that "A" will come before "a"). Non-alphabetic data is sorted according to the ASCII collating order. Alphabetic data is inserted in this order where the lower case alphabetics would normally appear.
+DICtionary
causes the sort to ignore everything that isn't a letter or a digit. The case of letters is ignored in the comparison. Keys that compare equal according to this test will be compared again as raw text. This option may only be used with ASCII input.
+Numeric
indicates that the key contains a (possibly signed) number made up of ASCII characters. The number will be collected from the start of the key until a non-numeric character is found. If the number begins with a zero, it will taken to be octal; otherwise, it is taken as decimal.
+OCTal
indicates that the key contains a (possibly signed) octal number in ASCII characters. The number will be collected from the start of the key until a non-numeric character is found. The number does not need a leading zero, but it can only consist of the digits 0 to 7.
+DECimal
indicates that the key contains a (possibly signed) decimal number in ASCII characters. The number will be collected from the start of the key until a non-numeric character is found. The number will be taken as decimal regardless of leading zeroes.
+HEXadecimal
indicates that the key contains a hexadecimal number in ASCII characters. The number will be collected from the start of the key until BSORT finds a character which is neither numeric nor one of the letters from "a" to "f" (either upper or lower case).
+BINary
indicates that the key contains a (possibly signed) binary number in ASCII characters. The number will be collected from the start of the key until a non-numeric character is found. The number can only consists of ones and zeroes.
+FloatingPoint
indicates that the key contains a floating point number in ASCII characters. This may have a leading sign, a decimal point, and/or an exponent introduced with "E" or "e" (single precision), or "D" or "d" (double precision). The number will be collected from the start of the key until BSORT finds a character that cannot be part of a floating point number.
+DATe
indicates that the key contains a date. The date may be in any form recognized by the B library function GETDATE (see "expl b lib getdate"). This collating order dictates that records be sorted in chronological order.
+BinarySigned
indicates that the key contains a signed integer in normal binary representation (i.e. as a machine integer). This kind of key may be a maximum of 72 bits long (specification of key length is dealt with later).
+BinaryFloating
indicates that the key contains a floating point number in normal machine representation. This kind of key may be a maximum of 72 bits long. After the key has been obtained from each record, it will be padded out to 72 bits by adding zero bits on the end of the number; this makes it possible to sort such keys using standard double-precision floating point comparisons.
EIS Numeric Comparisons'
may be used in the sort by specifying one of the following key options.
+FloatingPoint4bit
+FloatingPoint9bit
+LeadingSigned4bit
+LeadingSigned9bit
+NotSigned4bit
+NotSigned9bit
+TrailingSigned4bit
+TrailingSigned9bit

The length of keys sorted using EIS comparisons must work out to less than 64 EIS digits.

+Location
sorts according to the location of a field in the record. This option is applicable when using BSORT's facilities for scanning a record and parsing it into fields. The sort is based on the position of a particular field within the record.
+Width
sorts according to the width of a particular field in the record. The wider the field, the later it comes in the collating sequence. For example, if you were to sort a dictionary according to width, you would obtain all the one-letter words, then the two-letter words, and so on.

See Also:

expl bsort
full description of BSORT
expl bsort batch
using BSORT in batch
expl bsort errors
error handling
expl bsort examples
examples of BSORT operations
expl bsort keyopt
key options
expl bsort notes
miscellaneous notes
expl bsort options
general command line options
expl bsort position
key position descriptors

Copyright © 1996, Thinkage Ltd.