Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
Synctool for getting the ratio in output

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
Arun Raj

Moderator


Joined: 17 Oct 2006
Posts: 2285
Location: @my desk

PostPosted: Tue Sep 04, 2007 2:54 am    Post subject: Synctool for getting the ratio in output
Reply with quote

Hi,

My input file(record length-37) is
Code:
00256011613206aaaaaaaaaaaaaaa00111111
00256011613206bbbbbbbbbbbbbbb00111111
00256011613206ccccccccccccccc00111111
00256011613206ddddddddddddddd00111111
00256011613206eeeeeeeeeeeeeee00111111
00256011613203aaaaaaaaaaaaaaa00222222
00256011613203bbbbbbbbbbbbbbb00222222
00256011613203ccccccccccccccc00222222
00256011613203ddddddddddddddd00222222
00256011613203eeeeeeeeeeeeeee00222222
00256011613202aaaaaaaaaaaaaaa00333333
00256011613202bbbbbbbbbbbbbbb00333333
00256011613202ccccccccccccccc00333333
00256011613202ddddddddddddddd00333333
00256011613202eeeeeeeeeeeeeee00333333


Required output file (record length-58)
Code:
0025 60 1 16 132 06 aaaaaaaaaaaaaaa 0.2
0025 60 1 16 132 06 bbbbbbbbbbbbbbb 0.2
0025 60 1 16 132 06 ccccccccccccccc 0.2
0025 60 1 16 132 06 ddddddddddddddd 0.2
0025 60 1 16 132 06 eeeeeeeeeeeeeee 0.2
0025 60 1 16 132 03 aaaaaaaaaaaaaaa 0.2
0025 60 1 16 132 03 bbbbbbbbbbbbbbb 0.2
0025 60 1 16 132 03 ccccccccccccccc 0.2
0025 60 1 16 132 03 ddddddddddddddd 0.2
0025 60 1 16 132 03 eeeeeeeeeeeeeee 0.2
0025 60 1 16 132 02 aaaaaaaaaaaaaaa 0.2
0025 60 1 16 132 02 bbbbbbbbbbbbbbb 0.2
0025 60 1 16 132 02 ccccccccccccccc 0.2
0025 60 1 16 132 02 ddddddddddddddd 0.2
0025 60 1 16 132 02 eeeeeeeeeeeeeee 0.2

I need to group the records on charcters 1:14 and sum up the last numeric field and write the output file with the last field(numeric-S9(08)V9(06)) as the ratio of original no to the total sum.
ie.
111111/(111111*5) = 0.2

Is it possible by any means using a single SYNCSORT/SYNCTOOL step.??
Back to top
View user's profile Send private message

krisprems

Active Member


Joined: 27 Nov 2006
Posts: 649
Location: India

PostPosted: Tue Sep 04, 2007 9:44 am    Post subject:
Reply with quote

arcvns
Did you not try with the solution provided by Frank here=>
http://ibmmainframes.com/viewtopic.php?t=24145
The solution provided by frank is good enough to work with SYNCSORT/SYNCTOOL.
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 -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Subtract the ZD fields to provide neg... Balaryan DFSORT/ICETOOL 4 Wed Oct 11, 2017 10:51 pm
No new posts Where is output from PARM ABEXIT (SNA... packerm CA Products 3 Thu Sep 28, 2017 4:06 pm
No new posts Garbage on output file Hervey Martinez SYNCSORT 4 Wed Sep 27, 2017 12:50 am
No new posts it is possible output a SET value fro... Martylin JCL & VSAM 5 Fri Sep 22, 2017 7:08 am
No new posts Split 1 file into 10 output Files - S... Prasanth Kumar SYNCSORT 5 Sat Sep 16, 2017 12:02 am

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us