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
 

 

How to divide total of Two different fields Thru trailer

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

New User


Joined: 24 Dec 2007
Posts: 13
Location: Mumbai

PostPosted: Tue May 27, 2008 8:03 pm    Post subject: How to divide total of Two different fields Thru trailer
Reply with quote

Hi,

Consider below example
There are two fields one is number of Times card number swipe at particular merchant and total amount now I need to find the average Card member spent at each merchant. How can I do by Sysnccort

Example:
Code:
CM              Number of Swipes      total Amount  merchant
0001                     2                      100                 Pizza hut
0001                     3                      200                 Dominzos
0001                     5                      1000                Shoppers stop

Now should create the trailer records in the below format
Total no of swipes : 10
Total amount : 1300
Average amount : 130 (1300/10)


For this I have used the below Syntax but it is giving error can you please
help to resolve:
Code:
TRAILER1=(001:132C'-',                                 
          /,                                           
          001:C'|',                                     
          002:C'TOTALS          ',                     
          018:C'|',                                     
          037:TOTAL=(011,005,PD,                       
              EDIT=(IIIIIITTT)),                       
          046:C'|',                                     
                  *                                     
     052:(TOT=(024,008,PD),DIV,TOT=(011,005,PD)),       
              EDIT=(S$I,III,III,III,IIT.TT),SIGNS=(,-)),
          074:C'|',                                     081:TOTAL=(024,008,PD,                       
              EDIT=(S$I,III,III,III,IIT.TT),SIGNS=(,-)),
          103:C'|',                                     
          110:TOTAL=(032,008,PD,                       
              EDIT=(S$I,III,III,III,IIT.TT),SIGNS=(,-)),
          132:C'|',                                     
          /,                                           
       132:C'|',   
       /,         
      001:132C'-')
Back to top
View user's profile Send private message

dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Wed May 28, 2008 3:41 am    Post subject:
Reply with quote

Hello,

Please post your complete jcl and control statements as well as the diagnostic info from the jes output.

When you post, use the "Code" tag near the top of the reply panel. To make sure your post will appear as you want, use the Preview (below the text window). Once you have edited and Previewed and your post appears as you want, click Submit. If you forget to Submit, you get to enter your post again. . .
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 Syncsort Help to group fields sudhakarraju SYNCSORT 6 Thu Dec 29, 2016 1:38 am
No new posts How to update a portion of text in a ... Bill Woodger DFSORT/ICETOOL 25 Wed Nov 09, 2016 9:41 pm
No new posts Access SQLCA fields inside a stored p... gangapd DB2 4 Thu Oct 27, 2016 10:20 am
No new posts Need Help to Define 36 Input Fields (... satish.ms10 CLIST & REXX 2 Sat May 07, 2016 3:08 pm
No new posts FileAid to compare(logical operations... anand1204 Compuware & Other Tools 3 Wed Apr 06, 2016 2:55 am


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