IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Modify Several JCLs at the Same Time


IBM Mainframe Forums -> JCL & VSAM
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
rebull

New User


Joined: 20 Dec 2020
Posts: 3
Location: US

PostPosted: Sun Dec 20, 2020 2:03 am
Reply with quote

Hi!

I have the need of modify the same line or insert the same change on 20 JCLs at the same time, is that possible?

Example

Library:

WORK.JCLS.DESTINO.LIB(JCLMOD01)
WORK.JCLS.DESTINO.LIB(JCLMOD02)
WORK.JCLS.DESTINO.LIB(JCLMOD03)

Let's say I have into the JCLs the following lines,

JCLMOD01
Code:
EDIT       WORK.JCLS.DESTINO.LIB(JCLMOD01) - 01.03         Columns 00001 00072
Command ===>                                                  Scroll ===> CSR 
000312 //*                                                                     
000313 //RESUME EXEC PGM=SORT,COND=(04,LT)                                     
000314 //SYSOUT   DD SYSOUT=*                                                 
000315 //SORTIN   DD DSN=WORK.JCLS.INSERTX.SORTOUT,DISP=SHR     
000316 //              DD DSN=WORK.JCLS.CHGRECX.SORTOUT,DISP=SHR     
000319 //DELTA     DD DSN=WORK.JCLS.RESUME.DELTA.D%%ODATE,       
000320 //              DISP=(,CATLG,DELETE),                                     
000321 //              SPACE=(TRK,(150,150),RLSE)                               
000322 //SYSIN    DD *                                                         
000323     SORT FIELDS=COPY                                                     
000324    OUTFIL FNAMES=DELTA                                                 
000325 //*                                                                     


JCLMOD02
Code:
EDIT       WORK.JCLS.DESTINO.LIB(JCLMOD02) - 01.03         Columns 00001 00072
Command ===>                                                  Scroll ===> CSR 
000312 //*                                                                     
000313 //RESUME EXEC PGM=SORT,COND=(04,LT)                                     
000314 //SYSOUT   DD SYSOUT=*                                                 
000315 //SORTIN   DD DSN=WORK.JCLS.INSERTX.SORTOUT,DISP=SHR     
000316 //              DD DSN=WORK.JCLS.CHGRECX.SORTOUT,DISP=SHR     
000319 //DELTA     DD DSN=WORK.JCLS.RESUME.DELTA.D%%ODATE,       
000320 //              DISP=(,CATLG,DELETE),                                     
000321 //              SPACE=(TRK,(150,150),RLSE)                               
000322 //SYSIN    DD *                                                         
000323     SORT FIELDS=COPY                                                     
000324    OUTFIL FNAMES=DELTA                                                 
000325 //*                                 


JCLMOD03
Code:
EDIT       WORK.JCLS.DESTINO.LIB(JCLMOD03) - 01.03         Columns 00001 00072
Command ===>                                                  Scroll ===> CSR 
000312 //*                                                                     
000313 //RESUME EXEC PGM=SORT,COND=(04,LT)                                     
000314 //SYSOUT   DD SYSOUT=*                                                 
000315 //SORTIN   DD DSN=WORK.JCLS.INSERTX.SORTOUT,DISP=SHR     
000316 //              DD DSN=WORK.JCLS.CHGRECX.SORTOUT,DISP=SHR     
000319 //DELTA     DD DSN=WORK.JCLS.RESUME.DELTA.D%%ODATE,       
000320 //              DISP=(,CATLG,DELETE),                                     
000321 //              SPACE=(TRK,(150,150),RLSE)                               
000322 //SYSIN    DD *                                                         
000323     SORT FIELDS=COPY                                                     
000324    OUTFIL FNAMES=DELTA                                                 
000325 //*           


As we can see in the 3 JCLs we have the same lines

Now let's say I want to introduce the same lines into all the 3 JCLs, how can I do that at the same time?

JCLMOD0*
Code:
EDIT       WORK.JCLS.DESTINO.LIB(JCLMOD0*) - 01.03         Columns 00001 00072
Command ===>                                                  Scroll ===> CSR 
000312 //*                                                                     
000313 //RESUME EXEC PGM=SORT,COND=(04,LT)                                     
000314 //SYSOUT   DD SYSOUT=*                                                 
000315 //SORTIN   DD DSN=WORK.JCLS.INSERTX.SORTOUT,DISP=SHR     
000316 //              DD DSN=WORK.JCLS.CHGRECX.SORTOUT,DISP=SHR
000319 //DELTA     DD DSN=WORK.JCLS.RESUME.DELTA.D%%ODATE,       
000320 //              DISP=(,CATLG,DELETE),                                     
000321 //              SPACE=(TRK,(150,150),RLSE)                               
000322 //SYSIN    DD *                                                         
000323     SORT FIELDS=COPY                                                     
000324    OUTFIL FNAMES=DELTA                                                 
000325 //*           
/*                                                                     
//*  NEW LINES TO BE ADDED                                                                   
//CONTA    EXEC PGM=SORT,COND=(4,LT)                                   
//SORTIN   DD DSN=WORK.JCLS.RESUME.DELTA.D%%ODATE,DISP=SHR
//SORTOUT  DD DSN=WORK.JCLS.RESUME.CONTA.SORTOUT,               
//            DISP=(,CATLG,DELETE),                                     
//            SPACE=(TRK,(20,5),RLSE),                                 
//            DCB=(LRECL=80,BLKSIZE=0)                                 
//SYSOUT   DD SYSOUT=*                                                 
//SYSIN    DD *                                                         
  SORT FIELDS=COPY                                                     
  OUTFIL FNAMES=SORTOUT,                                               
   TRAILER1=(01:' %%JOBNAME %%ODATE DELTA     COUNT: ', -     
   COUNT=(M11,LENGTH=8)),NODETAIL                                       
//*                                                                     



thank you so much in advance for your time
Back to top
View user's profile Send private message
Nic Clouston

Global Moderator


Joined: 10 May 2007
Posts: 2454
Location: Hampshire, UK

PostPosted: Sun Dec 20, 2020 3:09 pm
Reply with quote

You could have done it using cut and paste in less time than it took you to write the post and even less time if you used the JCL INCLUDE statement. And, for 20 members, cut and paste is probably the quickest way, anyway.
Back to top
View user's profile Send private message
Willy Jensen

Active Member


Joined: 01 Sep 2015
Posts: 724
Location: Denmark

PostPosted: Sun Dec 20, 2020 3:50 pm
Reply with quote

You can't. I go with Nic, use cut and paste.
However, looking a your JCL I see datasetname with D%%ODATE, which leads me to believe that those members are base for generated JCL. IBM Tivoli Workload Scheduler? Do the JCL generator have an INCLUDE feature?
Back to top
View user's profile Send private message
rebull

New User


Joined: 20 Dec 2020
Posts: 3
Location: US

PostPosted: Mon Dec 21, 2020 12:02 am
Reply with quote

thank you for your replies, like I imagine cut and paste several times it's the only option.

sorry what do you mean with Include?
Back to top
View user's profile Send private message
sergeyken

Senior Member


Joined: 29 Apr 2008
Posts: 2119
Location: USA

PostPosted: Mon Dec 21, 2020 1:38 am
Reply with quote

rebull wrote:
thank you for your replies, like I imagine cut and paste several times it's the only option.

sorry what do you mean with Include?

RTFM: “JCL Manual. INCLUDE statement”
Back to top
View user's profile Send private message
rebull

New User


Joined: 20 Dec 2020
Posts: 3
Location: US

PostPosted: Mon Dec 21, 2020 1:52 am
Reply with quote

sergeyken wrote:
rebull wrote:
thank you for your replies, like I imagine cut and paste several times it's the only option.

sorry what do you mean with Include?

RTFM: “JCL Manual. INCLUDE statement”


oh, you're right I understand now.

thank you for your hep
Back to top
View user's profile Send private message
Willy Jensen

Active Member


Joined: 01 Sep 2015
Posts: 724
Location: Denmark

PostPosted: Mon Dec 21, 2020 3:05 am
Reply with quote

Actually I meant Tivoli Scheduler, I'm pretty sure it has an include feature. The JCL INCLUDE, or private procedure libraries, was already mentioned by Nic.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> JCL & VSAM

 


Similar Topics
Topic Forum Replies
No new posts To get the the current time DFSORT/ICETOOL 13
No new posts RC query -Time column CA Products 3
No new posts C Compile time time stamps Java & MQSeries 10
No new posts Parallelization in CICS to reduce res... CICS 4
No new posts Insert system time/date (timestamp) u... DFSORT/ICETOOL 5
Search our Forums:

Back to Top