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
 

 

Question on JCL Restart

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> Mainframe Interview Questions
View previous topic :: :: View next topic  
Author Message
trushant.w

New User


Joined: 22 Sep 2013
Posts: 81
Location: pune india

PostPosted: Mon Feb 24, 2014 6:49 pm    Post subject: Question on JCL Restart
Reply with quote

In Capg i faced below question

In a proc there are 10 step
From jCL i need to run only 5th and 6th step of PROC

I cannot edit PROC and cannot use IEBEDIT
Back to top
View user's profile Send private message

Terry Heinze

JCL Moderator


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

PostPosted: Mon Feb 24, 2014 7:51 pm    Post subject:
Reply with quote

If you truly cannot edit the PROC in any way, the only option I can think of is to make a copy of the original PROC and include only the 5th and 6th steps in it.
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 Feb 24, 2014 8:28 pm    Post subject:
Reply with quote

Hello,

I wonder just who comes up with this kind of "requirement" . . . icon_confused.gif

One would hope that the need be met without strange little limiting rules. . .
Back to top
View user's profile Send private message
David Robinson

Active User


Joined: 21 Dec 2011
Posts: 175
Location: UK

PostPosted: Mon Feb 24, 2014 9:00 pm    Post subject:
Reply with quote

As Terry has said, you could make a copy of the proc and add a JCLLIB statement pointing to the alternate library.

Or you could copy the proc to the jobcard using PROC/PEND and tailor it accordingly.

Or you could code a RESTART statement to start the job from the 5th step and then code COND.stepname=(0,LE) statements after the EXEC PROC for steps 7 - 10.
Back to top
View user's profile Send private message
Nic Clouston

Global Moderator


Joined: 10 May 2007
Posts: 1715
Location: UK

PostPosted: Mon Feb 24, 2014 9:32 pm    Post subject: Reply to: Question on Restart
Reply with quote

Or restart at step 5 as normal and use an override that will insert a JCL error into step 7 but will only produce an error when step 7 tries to start.
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 Feb 24, 2014 10:00 pm    Post subject:
Reply with quote

Hello,

This question (with slightly different specifics) comes up rather often here and in similar forums.

I just don't understand how it comes up so often with the "can't do this" can't do that" restrictions. . . icon_confused.gif

Might this be some kind of quiz or contest?
Back to top
View user's profile Send private message
Rohit Umarjikar

Senior Member


Joined: 21 Sep 2010
Posts: 1610
Location: NY,USA

PostPosted: Tue Feb 25, 2014 1:07 am    Post subject:
Reply with quote

Quote:
Might this be some kind of quiz or contest?


Very true..

Basically in a interview, interviwer has only specific questions list to ask and if you don't answer towhat they exactly wants to hear then your are out of the quiz... icon_smile.gif

Also except 5th and 6th step keep a dummy file ovverride from JCL.[/quote]
Back to top
View user's profile Send private message
sureshpathi10

Active User


Joined: 03 May 2010
Posts: 154
Location: Kuala Lumpur

PostPosted: Tue Feb 25, 2014 9:02 am    Post subject:
Reply with quote

You're right Rohit... icon_biggrin.gif

Restart from 5th step and from step7 onwards override all step's COND parameter in a way that they won't execute.
Back to top
View user's profile Send private message
Pandora-Box

Moderator


Joined: 07 Sep 2006
Posts: 1529
Location: Andromeda Galaxy

PostPosted: Tue Feb 25, 2014 10:50 am    Post subject:
Reply with quote

The sad part is questions are asked just for the sake as somet hing should be asked
Back to top
View user's profile Send private message
TheMFKid

New User


Joined: 20 Nov 2013
Posts: 91
Location: India

PostPosted: Tue Feb 25, 2014 11:04 am    Post subject:
Reply with quote

Pandora-Box wrote:
The sad part is questions are asked just for the sake as somet hing should be asked

or may be as a test to analyze the how the person respond/react to such questions, and not exactly to hear the right/perfect answer.
Back to top
View user's profile Send private message
trushant.w

New User


Joined: 22 Sep 2013
Posts: 81
Location: pune india

PostPosted: Tue Feb 25, 2014 12:00 pm    Post subject:
Reply with quote

Thank you all for your thoughts


Quote:
or may be as a test to analyze the how the person respond/react to such questions, and not exactly to hear the right/perfect answer.


Completly agreed with you TheMFKid

Quote:
Might this be some kind of quiz or contest?

Yah its was like rapid fire round..... icon_question.gif

They were looking for answers provided by Nic and David.
Back to top
View user's profile Send private message
Ed Goodman

Active Member


Joined: 08 Jun 2011
Posts: 556
Location: USA

PostPosted: Tue Feb 25, 2014 8:52 pm    Post subject:
Reply with quote

Restart in 5th step, do one of these:

-after 6th step completes, but before 7th step starts, pull the plug on the mainframe.

-Override a dataset into the 7th step that creates a duplicate file, JES will stop the job

-Override 7th's step steplibs to not have the required program in them, step will get S806 and stop the job (if program is not in joblib or linklist)

-Change the program in step 7 to fail with an S806

-Change program in step 6 to abend after it's done. Override the dataset dispositions to leave files as you want them. e.g. (new,catlg,catlg)

All of these could leave files in the wrong state, but that wasn't the question
Back to top
View user's profile Send private message
Rohit Umarjikar

Senior Member


Joined: 21 Sep 2010
Posts: 1610
Location: NY,USA

PostPosted: Wed Feb 26, 2014 5:08 am    Post subject:
Reply with quote

Quote:
after 6th step completes, but before 7th step starts, pull the plug on the mainframe.


Best one... icon_smile.gif
Back to top
View user's profile Send private message
trushant.w

New User


Joined: 22 Sep 2013
Posts: 81
Location: pune india

PostPosted: Wed Feb 26, 2014 5:34 pm    Post subject:
Reply with quote

Quote:
after 6th step completes, but before 7th step starts, pull the plug on the mainframe.


Really intresting........... icon_lol.gif
Back to top
View user's profile Send private message
Terry Heinze

JCL Moderator


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

PostPosted: Wed Feb 26, 2014 8:01 pm    Post subject:
Reply with quote

Quote:
-after 6th step completes, but before 7th step starts, pull the plug on the mainframe.
Requires a high degree of hand/eye coordination. icon_lol.gif
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: Wed Feb 26, 2014 8:34 pm    Post subject:
Reply with quote

Long ago (60's - 70's) there was a service named RINGBELL that when invoked would sound the alarm on the 360/370.

If the code to "ring the bell" was run before step 7, this might signal the operator to pull the plug . . . Quickly . . . icon_cool.gif

Never mind the stuff running everywhere else icon_wink.gif
Back to top
View user's profile Send private message
Ed Goodman

Active Member


Joined: 08 Jun 2011
Posts: 556
Location: USA

PostPosted: Wed Feb 26, 2014 9:43 pm    Post subject:
Reply with quote

Wasn't there also a 'fling printer cover open' command? Useful for when your nemesis has a habit of placing boxed of non-sequenced punch cards on any available printer top.
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: Wed Feb 26, 2014 10:23 pm    Post subject:
Reply with quote

Yup, if you issued a skip-to-end-of box, the cover would open when the box was empty.

This was also a deterrent to setting drinks on the cover
Back to top
View user's profile Send private message
Kayathri K

New User


Joined: 25 Sep 2013
Posts: 4
Location: India

PostPosted: Thu Feb 27, 2014 5:25 pm    Post subject:
Reply with quote

Quote:

I wonder just who comes up with this kind of "requirement" . . .

One would hope that the need be met without strange little limiting rules. . .



I agree that this is a strange requirement. But I have come across these questions mostly in interviews.

And the answer they expect is using RESTART and COND statements.
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 -> Mainframe Interview Questions All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Fault Analyzer - listings question. egrove IBM Tools 4 Thu Aug 11, 2016 5:31 pm
No new posts dataset copy question - REPRO or some... atulxp TSO/ISPF 2 Wed Aug 03, 2016 10:56 pm
No new posts SQL Order By related question Joseph K Thomas DB2 8 Fri Mar 18, 2016 12:53 pm
No new posts DFSort Question krrp DFSORT/ICETOOL 9 Mon Mar 07, 2016 7:11 pm
No new posts SEQNUM and RESTART zh_lad DFSORT/ICETOOL 2 Tue Aug 25, 2015 8:17 pm


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