On Fri, 3 Apr 2009 10:26:02 -0600, Steve Comstock <[email protected]>
wrote:

>Darth Keller wrote:
>> A co-work has  a list of 4 digit UCB's - hexidecimal values - and want's
>> to sort it as hex-values.  It wouldn't be too hard to code up an edit
>> macro to perform the function, but I don't want to re-invent the wheel and
>> thought I'd check to see if I'm missing something that already exists. Any
>> one know of such a beast?
>> darth
>
>I don't see the problem. Get into edit of the file, and issue
>
>    ==> sort col1 col2 {A|D}
>
>where "col1" indicates the first byte of your UCB value
>and "col2" indicates the last byte; who cares if they're
>hex? Should work as is; ISPF will treat them as unexamined
>data and sort by the content.
>
>
>
>Kind regards,
>
>-Steve Comstock
>The Trainer's Friend, Inc.

I think that the OP means that the data is in DISPLAYABLE hex such as:

0010
001A
0022
002C

and wants the characters A..F to sort after the characters 0..9

What I do in this case is:

c c'a' x'fa' col1 col2 all
c c'b' x'fb' col1 cols all
c c'c' x'fc' col1 cols all
c c'd' x'fd' col1 cols all
c c'e' x'fe' col1 cols all
c c'e' x'ff' col1 cols all
sort col1 col2
c x'fa' c'a' col1 col2 all
c x'fb' c'b' col1 col2 all
c x'fc' c'b' col1 col2 all
c x'fd' c'd' col1 col2 all
c x'fe' c'e' col1 col2 all
c x'ff' c'a' col1 col2 all

--

John

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html

Reply via email to