Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

sorting records with format=ch using syncsort

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> SYNCSORT
View previous topic :: :: View next topic  
Author Message
Harsha1525

New User


Joined: 22 Dec 2009
Posts: 24
Location: hyderabad

PostPosted: Thu Dec 13, 2012 3:08 pm    Post subject: sorting records with format=ch using syncsort
Reply with quote

HI
This is my sort JCL

Code:
//SORT EXEC PGM=SORT                       
Sort input:
aaaaa11
aaaaa33
aaaaa22
My Sort card:
//SYSIN   DD *             
  SORT FIELDS=(01,07,CH,A)
/*       

I am expecting result as:
Code:
aaaaa11
aaaaa22
aaaaa33

But I am getting result as:
Code:
aaaaa11
aaaaa33
aaaaa22

I am in the impression that aaaaa33 greater than aaaaa22. but it is not. I am confused with above result and not sure why my result is different. not sure if I am doing anything silly here
Back to top
View user's profile Send private message

enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10274
Location: italy

PostPosted: Thu Dec 13, 2012 3:15 pm    Post subject: Reply to: sorting records with format=ch using syncsort
Reply with quote

what is the record format of Your input file

seems that it is a variable record,
for variable records You should take into account the 4 byte RDW
Code:
SORT FIELDS=(05,07,CH,A)
Back to top
View user's profile Send private message
Harsha1525

New User


Joined: 22 Dec 2009
Posts: 24
Location: hyderabad

PostPosted: Fri Dec 14, 2012 11:11 am    Post subject: Re: Reply to: sorting records with format=ch using syncsort
Reply with quote

enrico-sorichetti wrote:
what is the record format of Your input file

seems that it is a variable record,
for variable records You should take into account the 4 byte RDW
Code:
SORT FIELDS=(05,07,CH,A)



Hmmm. You are correct.my input file is VB I simply created thru ISPF 3.2 option with out observing the format of referred dataset.this is really silly mistake.thank you for your reply
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> SYNCSORT All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Need to write record of PS File in ex... Chandan1993 JCL & VSAM 1 Wed Jun 07, 2017 1:35 am
No new posts Sorting of hex values Saurabh_mi DFSORT/ICETOOL 11 Thu May 25, 2017 3:49 pm
No new posts Check if any Detail records and extra... V S Amarendra Reddy SYNCSORT 19 Mon May 08, 2017 8:54 pm
No new posts Format record to remove Leading zeroes Learncoholic DFSORT/ICETOOL 14 Wed Apr 05, 2017 2:43 pm
No new posts How to pick only YYMMDD from DATE1P (... atulbaviskar SYNCSORT 7 Wed Mar 22, 2017 11:39 am


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us