JCl Restart VSAMinit



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

JCl Restart VSAMinit

Postby Krishna kumar B » Fri Jul 19, 2013 4:22 pm

Hi ,


sample Jcl
************
JOB msgclass=A ............................
.
.
.
PROC1 EXEC PROC1
PROC2 EXEC PROC2
****************
procs
*****************
PROC1 PROC
..
STEP010 EXEC XXXX
XXXXXXXXX

STEP020 EXEC VSAMINIT, DSN= ABCD.EDF.GDE,DISP=SHR
****************
PROC2 PROC
..
STEP005 EXEC XXXX
XXXXXXXXX

STEP020 EXEC VSAMINIT, DSN= EDF.GDE.FGHR,DISP=SHR

***************


I want to restart the job fromSTEP20 of PROC2
i gave Restart Card in the Job( RESTART=VSAMINIT.STEP20) it executed from PROC1 rather than PROC2.
kindly help.
Krishna kumar B
 
Posts: 2
Joined: Fri Jul 19, 2013 3:14 pm
Has thanked: 0 time
Been thanked: 0 time

Re: JCl Restart VSAMinit

 

Re: JCl Restart VSAMinit

Postby NicC » Fri Jul 19, 2013 4:47 pm

How about cleaning up your JCL - 1 procedure per job, no nested procedures? For your immediate problem comment out or delete procedure 1 from you job - cancel after submission so that thatever you did is backed out.
The problem I have is that people can explain things quickly but I can only comprehend slowly.
Regards
Nic
NicC
Global moderator
 
Posts: 2690
Joined: Sun Jul 04, 2010 12:13 am
Location: Pushing up the daisys (almost)
Has thanked: 4 times
Been thanked: 105 times

Re: JCl Restart VSAMinit

Postby Robert Sample » Fri Jul 19, 2013 4:51 pm

Did you read the JOB statement RESTART option details in the JCL Reference manual? Did you read, in particular, the caution that STEPNAME.PROCSTEPNAME must be unique within the job or the results are unpredictable? Now you know why the caution is in the manual.
Robert Sample
Global moderator
 
Posts: 3367
Joined: Sat Dec 19, 2009 8:32 pm
Location: East Dubuque, Illinois
Has thanked: 1 time
Been thanked: 222 times

Re: JCl Restart VSAMinit

Postby Krishna kumar B » Fri Jul 19, 2013 5:23 pm

Nic and Robert,
agreed...

i dont have acess to datasets , Job is in production. I can only provide Restart Parm for an operator to proceed..
Krishna kumar B
 
Posts: 2
Joined: Fri Jul 19, 2013 3:14 pm
Has thanked: 0 time
Been thanked: 0 time

Re: JCl Restart VSAMinit

Postby Robert Sample » Fri Jul 19, 2013 5:59 pm

You need to get with your production support people and get the PROC changes made. The system did exactly what the manual told you it would do -- gave you unpredictable results when you attempted to do something the system told you would give you unpredictable results. There is no way you can resolve this on your own; either a production JCL change is required, or you must accept that you cannot do the RESTART you tried.
Robert Sample
Global moderator
 
Posts: 3367
Joined: Sat Dec 19, 2009 8:32 pm
Location: East Dubuque, Illinois
Has thanked: 1 time
Been thanked: 222 times

Re: JCl Restart VSAMinit

Postby Akatsukami » Fri Jul 19, 2013 9:10 pm

Krishna kumar B wrote:Hi ,


sample Jcl (so-called; this isn't very close)
JOB  msgclass=A ............................
.
.
.
PROC1  EXEC PROC1
PROC2 EXEC PROC2 

procs
PROC1 PROC
..
STEP010 EXEC  XXXX
XXXXXXXXX

STEP020  EXEC VSAMINIT, DSN= ABCD.EDF.GDE,DISP=SHR
****************
PROC2 PROC
..
STEP005 EXEC  XXXX
XXXXXXXXX

STEP020  EXEC VSAMINIT, DSN= EDF.GDE.FGHR,DISP=SHR

I want to restart the job fromSTEP20 of PROC2
i gave Restart Card in the Job( RESTART=VSAMINIT.STEP20) it executed from PROC1 rather than PROC2.
kindly help.

In addition to NicC's and Mr. Sample's warnings about nesting procedures, if you actually want to restart the job from STEP20 of PROC2, you should code
RESTART=PROC2.STEP020

on the job card; note that you want to use stepnames, not procnames (having the two be the same is confusing). You will benefit from (re-)reading about the RESTART parameter of the JOB card.
"You have sat too long for any good you have been doing lately ... Depart, I say; and let us have done with you. In the name of God, go!" -- what I say to a junior programmer at least once a day
User avatar
Akatsukami
Global moderator
 
Posts: 1053
Joined: Sat Oct 16, 2010 2:31 am
Location: Bloomington, IL
Has thanked: 6 times
Been thanked: 51 times


Return to JCL

 


  • Related topics
    Replies
    Views
    Last post