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
 

 

Batch File-Aid making use of READNEXT

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> Compuware & Other Tools
View previous topic :: :: View next topic  
Author Message
ramsri

Active User


Joined: 18 Oct 2008
Posts: 380
Location: India

PostPosted: Tue Feb 10, 2009 7:16 pm    Post subject: Batch File-Aid making use of READNEXT
Reply with quote

Hi,

I request you to post few batch File-Aid jobs that make use of READNEXT parameter. I read the programming guide but could not understand the exact usage of it because it does not have any examples !

Thanks.
Back to top
View user's profile Send private message

gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1703
Location: Australia

PostPosted: Fri Feb 13, 2009 7:51 am    Post subject:
Reply with quote

Hi,

an example of READNEXT
Code:
//* THE READNEXT PARAMETER ENABLES YOU TO CODE THE ACTION TO END       
//* PROCESSING OF THE CURRENT RECORD AND START THE FUNCTION OVER       
//* WITH THE NEXT RECORD.                                               
//*                                                                     
//FILEAID1 EXEC PGM=FILEAID                                             
//SYSPRINT DD SYSOUT=*                                                 
//DD01     DD *                                                         
12345S                                                                 
12345W                                                                 
12345R                                                                 
12345M                                                                 
//OUTS     DD SYSOUT=*                                                 
//OUTM     DD SYSOUT=*                                                 
//OUTO     DD SYSOUT=*                                                 
//SYSIN    DD *                                                         
$$DD01 USER IF=(06,EQ,C'W'),READNEXT,                                   
 IF=(06,EQ,C'S'),WRITE=OUTS,READNEXT,                                   
 IF=(06,EQ,C'M'),WRITE=OUTM,                                           
 DFLT_WRITE=OUTO                                                       
/*


Gerry
Back to top
View user's profile Send private message
ramsri

Active User


Joined: 18 Oct 2008
Posts: 380
Location: India

PostPosted: Sun Feb 15, 2009 6:22 pm    Post subject:
Reply with quote

Gerry, this example I found in the programming guide ! I would like to see more examples to have a clear understanding.

Please help. Thanks.
Back to top
View user's profile Send private message
Terry Heinze

JCL Moderator


Joined: 14 Jul 2008
Posts: 1249
Location: Richfield, MN, USA

PostPosted: Sun Feb 15, 2009 9:29 pm    Post subject:
Reply with quote

Ramsri,
First you said, "[the programming guide] does not have any examples", and now you say, "this example I found in the programming guide". Which is it?
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1703
Location: Australia

PostPosted: Mon Feb 16, 2009 3:19 am    Post subject:
Reply with quote

Hi,

see the 2 examples below and you should see the difference when you run them

Code:
//FILEAID1 EXEC PGM=FILEAID                                             
//SYSPRINT DD SYSOUT=*                                                 
//DD01     DD *                                                         
12345S                                                                 
12345M                                                                 
//OUTS     DD SYSOUT=*                                                 
//OUTM     DD SYSOUT=*                                                 
//OUTO     DD SYSOUT=*                                                 
//SYSIN    DD *                                                         
$$DD01 USER IF=(06,EQ,C'S'),WRITE=OUTS,READNEXT,                       
            IF=(06,EQ,C'M'),                                           
          ORIF=(06,EQ,C'S'),WRITE=OUTM,                                 
 DFLT_WRITE=OUTO                                                       
/*                                                                     
//**********************************************************************


Code:
//FILEAID1 EXEC PGM=FILEAID                                             
//SYSPRINT DD SYSOUT=*                                                 
//DD01     DD *                                                         
12345S                                                                 
12345M                                                                 
//OUTS     DD SYSOUT=*                                                 
//OUTM     DD SYSOUT=*                                                 
//OUTO     DD SYSOUT=*                                                 
//SYSIN    DD *                                                         
$$DD01 USER IF=(06,EQ,C'S'),WRITE=OUTS,                                 
            IF=(06,EQ,C'M'),                                           
          ORIF=(06,EQ,C'S'),WRITE=OUTM,                                 
 DFLT_WRITE=OUTO                                                       
//*                                                                     




Gerry
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 -> Compuware & Other Tools All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Converting Variable block file to Fix... bhavana yalavarthi DFSORT/ICETOOL 10 Tue May 16, 2017 2:20 pm
No new posts Getting error while opening a variabl... apandey1 COBOL Programming 5 Fri May 05, 2017 12:22 pm
No new posts Issue with NDM process to transmit ES... chetanambi All Other Mainframe Topics 6 Wed May 03, 2017 10:52 am
No new posts File processing vishwakotin Mainframe Interview Questions 9 Fri Apr 28, 2017 11:38 am
No new posts Occurrence of various strings within ... TS70363 JCL & VSAM 1 Thu Apr 27, 2017 8:18 pm


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