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
 

 

Find number of records in each of these files

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL
View previous topic :: :: View next topic  
Author Message
srinathangya

New User


Joined: 19 Dec 2005
Posts: 77

PostPosted: Mon Nov 17, 2008 8:40 am    Post subject: Find number of records in each of these files
Reply with quote

Hi Friends,
I have multiple files. Each file will be of different record length. And my task is to find number of records in each of these files and store it one single file. For this, I thought I could do this by SORT JCL and the output file should be File with recfm=V. And when i tried this, it didnt worked. Can anyone suggest me a solution?

Thanks
Srinath.
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: Mon Nov 17, 2008 8:51 am    Post subject:
Reply with quote

Hello,

Not from what you posted. . .

"It didn't work" tells us nothing.

Post your jcl, sort control statements, and the output presented by the sort including the message-ids. Use the "Code" tag to make your post more readable as well as preserve alighment.

Use Preview to see how your post will appear to the forum and when you are satisfied with how the post appears, Submit.
Back to top
View user's profile Send private message
Skolusu

Senior Member


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

PostPosted: Mon Nov 17, 2008 11:21 pm    Post subject: Reply to: Find number of records in each of these files
Reply with quote

srinathangya,

If all your input files are FB files then you can use the following JCL to get the desired results

Code:

//STEP0100 EXEC PGM=ICETOOL                     
//TOOLMSG  DD SYSOUT=*                           
//DFSMSG   DD SYSOUT=*                           
//IN01     DD DISP=SHR,DSN=File 01
//IN02     DD DISP=SHR,DSN=File 02
//IN03     DD DISP=SHR,DSN=File 03       
//IN04     DD DISP=SHR,DSN=File 04
//IN05     DD DISP=SHR,DSN=File 05
//IN06     DD DISP=SHR,DSN=File 06
//IN07     DD DISP=SHR,DSN=File 07

....add all your other files
/*
//OUT      DD DSN=Your output file with counts,
//            DISP=(MOD,CATLG,DELETE),   
//            UNIT=SYSDA,               
//            SPACE=(CYL,(5,1),RLSE)
/*
//TOOLIN   DD *                                 
  COPY FROM(IN01) USING(CTL1)                   
  COPY FROM(IN02) USING(CTL1)                   
  COPY FROM(IN03) USING(CTL1)                   
  COPY FROM(IN04) USING(CTL1)                   
  COPY FROM(IN05) USING(CTL1)                   
  COPY FROM(IN06) USING(CTL1)                   
  COPY FROM(IN07) USING(CTL1)
                   
.... add all your corresponding toolin statements
/*
//CTL1CNTL DD *                                 
  OUTREC BUILD=(SEQNUM,10,ZD,80:X)               
  OUTFIL FNAMES=OUT,REMOVECC,NODETAIL,           
  TRAILER1=('TOTAL NO: OF RECORDS : ',1,10)     
/*
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 -> DFSORT/ICETOOL All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts getting three output files out of JOI... migusd SYNCSORT 7 Mon Jun 05, 2017 11:30 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 find RACF group for access to spooled... jzhardy JCL & VSAM 1 Mon May 08, 2017 11:46 am
No new posts Unable to create multiple files using... mbattu COBOL Programming 3 Fri May 05, 2017 5:35 pm
No new posts SMTP the current generation number of... Jyothi Kulunde JCL & VSAM 4 Thu May 04, 2017 4:08 pm


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