SORT-MERGE/XL General User's Guide (32650-90883)

Chapter 6 69
SORT-MERGE/XL Commands
ALTSEQ
If you wish to do an alphabetic sorting in which each upper case letter collates ahead of the
corresponding lower case letter, use the command >ALTSEQ MERGE "A-Z" WITH "a-z".
The following six special characters follow the lower case z since the first range precedes
the second range:
[ \ ] ^ _ and `
If the
modspec
is MERGE "a-z" WITH "A-Z", the same six characters precede the lower
case a. For additional information, refer to the "EXAMPLES" section below.
Consider this form of
modspec
as a shorthand for the
modspec
specifying EACH. For
example, the command, >ALTSEQ MERGE "A-Z" WITH "a-z", is equivalent to the longer
command >ALTSEQ "AaBb...Zz"= "AB...Zab...z", where ... represents all the
necessary characters.
EXAMPLES
The following examples show how to use various parameters with the >ALTSEQ command,
as well as the resulting collating sequences.
Standard ASCII Collating Sequence
To display the standard collating sequence enter the DATA IS ASCII, SEQUENCE IS
ASCII and >SHOW SEQUENCE commands, as shown below. Refer to this display, for
comparative purposes, to see what occurs to the collating sequence when you use >ALTSEQ
for various functions in the following examples.
:SORT
HP32214A.01.00 SORT/3000 THU, JUN 4, 1987, 8:10 AM
©: HEWLETT-PACKARD CO. 1986
>DATA IS ASCII, SEQUENCE IS ASCII
>SHOW SEQUENCE
nul soh stx etx eot enq ack bel bs ht lf vt ff cr so si
dle dc1 dc2 dc3 dc4 nak syn etb can em sub esc fs gs rs us
sp ! " # $ % & ' ( ) * + , - . /
0 1 2 3 4 5 6 7 8 9 : ; < = > ?
@ A B C D E F G H I J K L M N 0
P Q R S T U V W X Y Z [ \ ] ^ _
` a b c d e f g h i j k l m n o
p q r s t u v w x y z { | } ~ del
Using the EACH Parameter
The following example shows how to use the >ALTSEQ command with the EACH parameter
followed by a
string
specification:
:SORT
HP32214A.01.00 SORT/3000 THU, JUN 4, 1987, 8:10 AM