IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Wrong data displayed in SORTOUT


IBM Mainframe Forums -> DFSORT/ICETOOL
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
Mariraj

New User


Joined: 09 Jul 2007
Posts: 59
Location: Chennai

PostPosted: Tue Jun 08, 2010 11:08 am
Reply with quote

I am using summation based on a 3-digit ZD field. The results are perfectly fine except that the last digit of the summed field is displayed as ‘E’ instead of ‘5’. When I do a ‘HEX ON’ on the output DS, the following is displayed. I am referring to the '18E' field.

Code:
8001 BILL   18E 890106 10                                               
FFFF4CCDD444FFC4FFFFFF4FF44444444444444444444444444444444444444444444444
800102933000185089010601000000000000000000000000000000000000000000000000


In HEX format, the data is proper. It contains C in the last nibble to indicate it is a positive value. But I m not sure why is it displaying ‘E’ instead of ‘5’. Please let me know the reason. I tried searching this forum but couldn't find an exact match. Please excuse me if it is a duplicate post and also let me know the post link.
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10873
Location: italy

PostPosted: Tue Jun 08, 2010 11:16 am
Reply with quote

meditate on the bible of Mainframe IT

POP ( Principles of Operations) SA22-7832-07
www-03.ibm.com/systems/z/os/zos/bkserv/r10pdf/


hint...
Code:
1234567890 = x'f1f2f3f4f5f6f7f8f9f0'
ABCDEFGHI  = x'c1c2c3c4c5c6c7c8c9'
Back to top
View user's profile Send private message
Mariraj

New User


Joined: 09 Jul 2007
Posts: 59
Location: Chennai

PostPosted: Tue Jun 08, 2010 11:32 am
Reply with quote

Thanks for the info. So this means whenever the result is a postive value, it wil be only A,B,C... based on whether it is +1,+2,..

Can you tell me how can we make it to display 185 instead of 18E. Do we need to change the format? If so what should be the format?
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10873
Location: italy

PostPosted: Tue Jun 08, 2010 11:37 am
Reply with quote

quoting one of Frank Yaeger posts

Quote:
If you are getting a C sign for Zd instead of an F sign, then you're using Syncsort, not DFSORT. DFSORT gives an F sign for TO=ZD. Try using TO=ZDF. And since you're using Syncsort, please post in the JCL Forum, not in the DFSORT Forum.


please confirm and I will move the topic where it belongs...

messages starting with ...
ICE... ==> DFSORT
WER... ==> SYNCSORT
Back to top
View user's profile Send private message
Mariraj

New User


Joined: 09 Jul 2007
Posts: 59
Location: Chennai

PostPosted: Tue Jun 08, 2010 11:48 am
Reply with quote

Messages are starting with ICE only
Back to top
View user's profile Send private message
hikaps14

Active User


Joined: 02 Sep 2005
Posts: 189
Location: Noida

PostPosted: Tue Jun 08, 2010 11:54 am
Reply with quote

You may also try

OPTION ZDPRINT

as given in below post http://www.ibmmainframes.com/about1639.html.

Thanks,
-Kapil.
Back to top
View user's profile Send private message
Mariraj

New User


Joined: 09 Jul 2007
Posts: 59
Location: Chennai

PostPosted: Tue Jun 08, 2010 12:04 pm
Reply with quote

I tried using the following.

Code:
OUTREC FIELDS=(1,12,13,3,ZD,EDIT=(TTT),16)


This helped to achieve what i wanted to i.e see the result as 185. Thanks to both of you.
Back to top
View user's profile Send private message
Skolusu

Senior Member


Joined: 07 Dec 2007
Posts: 2205
Location: San Jose

PostPosted: Tue Jun 08, 2010 10:44 pm
Reply with quote

Mariraj,

Since you are summing the default option at your shop may be NZDPRINT. Use the ZDPRINT option which will print the F sign. You don't have to use OUTREC with EDIT

ex:
Code:

//SYSIN    DD *             
  OPTION ZDPRINT           
  SORT FIELDS=(p,m,CH,A)   
  SUM FIELDS=(p,3,ZD)       
//*
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Developer


Joined: 15 Feb 2005
Posts: 7129
Location: San Jose, CA

PostPosted: Wed Jun 16, 2010 2:40 am
Reply with quote

Quote:
quoting one of Frank Yaeger posts

Quote:
If you are getting a C sign for Zd instead of an F sign, then you're using Syncsort, not DFSORT. DFSORT gives an F sign for TO=ZD. Try using TO=ZDF. And since you're using Syncsort, please post in the JCL Forum, not in the DFSORT Forum.


This was quoted out of context. I was talking about TOTAL, not SUM. For SUM, ZDPRINT=YES/NO (ZDPRINT/NZDPRINT) controls the sign.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> DFSORT/ICETOOL

 


Similar Topics
Topic Forum Replies
No new posts How to save SYSLOG as text data via P... All Other Mainframe Topics 2
No new posts WER247A SORTOUT HAS INCOMPATIBLE LRECL SYNCSORT 7
No new posts Store the data for fixed length COBOL Programming 1
No new posts Data set Rec-Cnt and Byte-Cnt Testing & Performance 2
No new posts SCOPE PENDING option -check data DB2 2
Search our Forums:

Back to Top