View previous topic :: View next topic
|
Author |
Message |
Shanmugavel_03
New User
Joined: 06 Oct 2010 Posts: 7 Location: Wilkes Barre, PA
|
|
|
|
Greetings !!!!
I am using the below sort card to sort these three alphanumeric variables. I was expecting an output that 04,05 and 0I will be the order of the output.
But i got the output as 0I,04,05. Now, the question is how does the sort in character format happens in syncsort (do they follow ascii numbers to sort these variables) or (do they follow any pattern to sort these 3 inputs)
//PS0070 EXEC PGM=SYNCSORT
//SYSPRINT DD SYSOUT=*
//SYSOUT DD SYSOUT=*
//SORTIN DD *
05
04
0I
//SORTOUT DD SYSOUT=*
//SYSIN DD *
SORT FIELDS=(1,2,CH,A) |
|
Back to top |
|
|
Craq Giegerich
Senior Member
Joined: 19 May 2007 Posts: 1512 Location: Virginia, USA
|
|
|
|
In EBCDIC letters are lower then digits. |
|
Back to top |
|
|
Robert Sample
Global Moderator
Joined: 06 Jun 2008 Posts: 8696 Location: Dubuque, Iowa, USA
|
|
|
|
Quote: |
do they follow ascii numbers to sort these variables |
Guaranteed not -- this is a mainframe, which uses EBCDIC not ASCII. |
|
Back to top |
|
|
Shanmugavel_03
New User
Joined: 06 Oct 2010 Posts: 7 Location: Wilkes Barre, PA
|
|
|
|
Thanks Robert and Craq for your response.... |
|
Back to top |
|
|
|