MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Sort + Sum problems

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Utilities
View previous topic :: View next topic  
Author Message
maxisnowhere
Beginner


Joined: 25 May 2005
Posts: 59
Topics: 20

PostPosted: Fri Sep 29, 2006 6:53 am    Post subject: Sort + Sum problems Reply with quote

Hi Guys,

hope not to repeat an old question, I've searched but not found...javascript:emoticon('Rolling Eyes')
Rolling Eyes

I have a file like:
Code:

AA 10.30
BB 200.50
AA 1000.00
BB 30.70

and I would like to obtain:

AA 1010.30
BB 231.20

I would like to use the SORT with the SUM, but I can't sum those decimal numbers. Can somebody help me?('Question')


Thank' s a lot!!
Max
Rolling Eyes
_________________
Maxisnowhere
Back to top
View user's profile Send private message
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12378
Topics: 75
Location: San Jose

PostPosted: Fri Sep 29, 2006 7:14 am    Post subject: Reply with quote

maxisnowhere,

Try this job

Code:

//STEP0100 EXEC PGM=SORT                         
//SYSOUT   DD SYSOUT=*                           
//SORTIN   DD *                                   
AA 10.30                                         
BB 200.50                                         
AA 1000.00                                       
BB 30.70                                         
//SORTOUT  DD SYSOUT=*                           
//SYSIN    DD *                                   
 SORT FIELDS=(1,2,CH,A)                           
 OUTFIL REMOVECC,NODETAIL,                       
 SECTIONS=(1,2,                                   
 TRAILER3=(1,2,X,TOT=(4,7,UFF,EDIT=(IIIIIIT.TT))))
/*                                               


Hope this helps...

Cheers

Kolusu
_________________
Kolusu
www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
maxisnowhere
Beginner


Joined: 25 May 2005
Posts: 59
Topics: 20

PostPosted: Fri Sep 29, 2006 7:23 am    Post subject: Reply with quote

Thank's a lot!!

Bye Maxisnowhere
_________________
Maxisnowhere
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Utilities All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group