Override DD-statements of an in-stream procedure



JES, JES2, JCL utilities, IDCAMS, Compile & Run JCLs, PROCs etc...

Override DD-statements of an in-stream procedure

Postby aldencarr123 » Sun Nov 15, 2020 3:40 am

I received a JCL error after submitting this job can anyone explain why?

//TSOZA48 JOB 3ES10G10000012,'TSOZA48',MSGCLASS=X,MSGLEVEL=(1,1),
// NOTIFY=TSOZA48,CLASS=A,REGION=2M
//********************************************************************
//* JOB SUBMITTED FROM userid.ES10.CNTL(LAB5#31) ***
//* DOC: Override DD-Statements on an Instream Procedure ***
//********************************************************************
//COMP PROC
//**********************************************************
//********* MAKE BACKUP
//**********************************************************
//S1 EXEC PGM=IEBCOPY
//SYSPRINT DD SYSOUT=*
//SYSUT1 DD DISP=SHR,DSN=userid.ES10.CNTL
//SYSUT2 DD DISP=(,CATLG),DSN=userid.ES10.BACK,
// LIKE=userid.ES10.CNTL
//SYSIN DD DUMMY
//IFOK1 IF (S1.RC=0) THEN
//**********************************************************
//********* COMPRESS DATA SET
//**********************************************************
//S2 EXEC PGM=IEBCOPY
//SYSPRINT DD SYSOUT=*
//SYSUT1 DD DISP=SHR,DSN=userid.ES10.CNTL
//SYSUT2 DD DISP=OLD,DSN=userid.ES10.CNTL
//SYSIN DD DUMMY
//IFOKEND1 ENDIF
//IFOK2 IF (S2.RC=0) THEN
//**********************************************************
//********* COMPRESS SUCCESSFUL, DELETE BACKUP
//**********************************************************
//S3 EXEC PGM=IEFBR14
//DD1 DD DISP=(OLD,DELETE),DSN=userid.ES10.BACK
//IFOKEND2 ENDIF
// PEND
//FINAL EXEC COMP
//S1.SYSUT1 DD DISP=SHR,DSN=TSOZA60.COPY.CNTL
//S1.SYSUT2 DD DISP=(,CATLG),DSN=TSOZA60.ES10.BACK,
// LIKE=TSOZA60.COPY.CNTL
//S2.SYSUT1 DD DISP=SHR,DSN=TSOZA60.COPY.CNTL
//S2.SYSUT2 DD DISP=OLD,DSN=TSOZA60.COPY.CNTL


Coded for you - last time
aldencarr123
 
Posts: 6
Joined: Wed Nov 11, 2020 4:14 am
Has thanked: 0 time
Been thanked: 0 time

Re: Override DD-statements of an in-stream procedure

Postby prino » Sun Nov 15, 2020 4:23 am

And we have to guess the error?

And
//IFOK2 IF (S2.RC=0) THEN
will very obviously be not very useful if S2 is not executed when S1 falls over.
Robert AH Prins
robert.ah.prins @ the.17+Gb.Google thingy
User avatar
prino
 
Posts: 641
Joined: Wed Mar 11, 2009 12:22 am
Location: Vilnius, Lithuania
Has thanked: 3 times
Been thanked: 29 times

Re: Override DD-statements of an in-stream procedure

Postby sergeyken » Sun Nov 15, 2020 6:25 am

My car doesn’t drive after I press Start button can anyone explain why?
Javas and Pythons come and go, but JCL and SORT stay forever.
User avatar
sergeyken
 
Posts: 438
Joined: Wed Jul 24, 2019 10:12 pm
Has thanked: 7 times
Been thanked: 40 times

Re: Override DD-statements of an in-stream procedure

Postby NicC » Sun Nov 15, 2020 5:20 pm

In other words: What was the JCL error? Show us the messages. Make it easy for us - some of us are busy and do not have much time to spare to help. Using the code tags when presenting code, data, control statements and reports helps people see the problem quicker so use them!
The problem I have is that people can explain things quickly but I can only comprehend slowly.
Regards
Nic
NicC
Global moderator
 
Posts: 3025
Joined: Sun Jul 04, 2010 12:13 am
Location: Pushing up the daisies (almost)
Has thanked: 4 times
Been thanked: 136 times

Re: Override DD-statements of an in-stream procedure

Postby willy jensen » Mon Nov 16, 2020 1:53 pm

the datasetnames in the instream proc are in lowercase. they are checked even though they are overridden.
willy jensen
 
Posts: 467
Joined: Thu Mar 10, 2016 5:03 pm
Has thanked: 0 time
Been thanked: 70 times


Return to JCL

 


  • Related topics
    Replies
    Views
    Last post