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
 

 

Is there a way to keep the second Job in a jcl WAIT for few.

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
rakeshreddy
Warnings : 1

New User


Joined: 21 Mar 2007
Posts: 28
Location: Bangalore

PostPosted: Tue Dec 09, 2008 12:24 am    Post subject: Is there a way to keep the second Job in a jcl WAIT for few.
Reply with quote

Hi Friends..

I have a JCL with couple of jobs in it..

Each step does has it's own usage...

is there a way to start the second job after 15 sec's the first job got submitted..and so forth to th next job..

AS below..

JOB1
---------15 SEC WAIT
JOB2
---------15 SEC WAIT
JOB3
---------15 SEC WAIT
and so on.........

i want to maintain the time gap of 15 sec between each job in the JCL..
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: Tue Dec 09, 2008 12:28 am    Post subject:
Reply with quote

Hello,

Quote:
i want to maintain the time gap of 15 sec between each job in the JCL..
What business reason might there be to do such a thing. . . . icon_confused.gif
Back to top
View user's profile Send private message
Arun Raj

Moderator


Joined: 17 Oct 2006
Posts: 2284
Location: @my desk

PostPosted: Tue Dec 09, 2008 12:31 am    Post subject:
Reply with quote

rakeshreddy,

I think you should be able to do this with the help of your scheduling team. But what is the reason behind this 15 sec "wait-tme"?
Back to top
View user's profile Send private message
superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4649
Location: Raleigh, NC, USA

PostPosted: Tue Dec 09, 2008 12:54 am    Post subject: Reply to: Is there a way to keep the second Job in a jcl WAI
Reply with quote

Rakesh, a search on the keywords "SLEEP" or "WAIT" ought to give you enough ideas to work with.
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: Tue Dec 09, 2008 1:01 am    Post subject:
Reply with quote

Hello,

Quote:
is there a way to start the second job after 15 sec's the first job got submitted..and so forth to th next job..
IMHO, i believe there should be an understanding of the requirement before solutions/suggestions/alternatives are offered. . .

Notice the request asks for the ability to wait 15 seconds after submission - not 15 seconds after the job starts or ends, but after being submitted.

As i asked originally, what business requirement might be served by doing this?

It sounds (so far) like this another of the things that are technically possible, but should not be done. . .
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: Tue Dec 09, 2008 9:32 am    Post subject:
Reply with quote

Quote:
It sounds (so far) like this another of the things that are technically possible, but should not be done. . .
Agree completely. Wasting initiatior time is highly undesireable.
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Tue Dec 09, 2008 12:10 pm    Post subject:
Reply with quote

HOMEWORK ???
Back to top
View user's profile Send private message
Anuj Dhawan

Senior Member


Joined: 22 Apr 2006
Posts: 6258
Location: Mumbai, India

PostPosted: Tue Dec 09, 2008 12:15 pm    Post subject:
Reply with quote

Hi,

You need to re-think how to implement your requirement the requirement is not to keep initiators waiting in some step - that is your attempt to meet the requirement.

I suspect that you want to wait until some condition is met. This could be hours or worse case - never.

If several people implemented their process doing as you want to do, the mainframe would come to a complete halt because all of the initiators/partitions were "waiting".
Back to top
View user's profile Send private message
rakeshreddy
Warnings : 1

New User


Joined: 21 Mar 2007
Posts: 28
Location: Bangalore

PostPosted: Tue Dec 09, 2008 3:58 pm    Post subject:
Reply with quote

Hi Friends..
below is the description:

I have a JCL with multiple jobs( above 50 jobs) in it.

and the JOB Card is SAME for all the jobs (including the JOB NAME and I can't chnage the job name)

My doubt is :

Will the Job's execute in the SAME ORDER as they are in JCL (or) they will execute in RANDOM order?

My requirement is the JOBS should execute in SAME order as they are in JCL..

So i thought of using a WAIT parameter to make the second job execute after 15 sec to First Job..

If any of you can confirm that " the jobs will execute in the SAME order as they are in JCL"... i no need to use any WAIT Parameter.. i can directly submit the jcl.

Please suggest me on this...
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Tue Dec 09, 2008 5:07 pm    Post subject:
Reply with quote

So why did you not spend 10 minutes setting up and testing this scenario, rather than post it on here ?

10 minutes is all that it would have took, if even that.
Back to top
View user's profile Send private message
Anuj Dhawan

Senior Member


Joined: 22 Apr 2006
Posts: 6258
Location: Mumbai, India

PostPosted: Tue Dec 09, 2008 5:32 pm    Post subject:
Reply with quote

Aaarghh..!
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8117
Location: East Dubuque, Illinois, USA

PostPosted: Tue Dec 09, 2008 5:55 pm    Post subject:
Reply with quote

Something to be aware of in the JCL Language Reference manual (emphasis added by me):
Quote:
In a JES2 system, there are a number of factors that determine the order in which a particular job is selected for execution. Therefore, you cannot be assured that job priority (based on the PRTY you assign a job), job class, or the order of job submission will guarantee that the jobs will execute in a particular order. If you need to submit jobs in a specific order, contact your JES2 system programmer for advice based on how your system honors such requests
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: Tue Dec 09, 2008 10:07 pm    Post subject:
Reply with quote

Hello,

Two ways to guarantee that the jobs run in order are to

1. Use the system scheduler
2. Have each job submit the subsequent job via the internal reader (job1 submits job2, job2 submits job3, etc.

IMHO, using the scheduler is the better choice.
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 -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
This topic is locked: you cannot edit posts or make replies. Job to wait and continue based on reply yugendran COBOL Programming 5 Wed Oct 05, 2016 1:46 pm
No new posts OMEGAMON to see In-DB2 times and Wait... Archana89 IBM Tools 4 Fri Mar 04, 2016 11:28 am
No new posts MQ message to wait for processing mohitsaini Java & MQSeries 1 Sat Jun 20, 2015 5:39 am
No new posts How to recall (or wait for recall of)... JPVRoff PL/I & Assembler 4 Wed Feb 18, 2015 9:19 am
No new posts CICS WAIT EVENT sureshjimmy CICS 2 Sat Sep 20, 2014 4:41 pm


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