DS scheduling

Post questions here relative to DataStage Server Edition for such areas as Server job design, DS Basic, Routines, Job Sequences, etc.

Moderators: chulett, rschirm, roy

Post Reply
sweetleaf
Participant
Posts: 30
Joined: Fri Jan 24, 2003 3:28 pm
Location: Canada

DS scheduling

Post by sweetleaf »

Hi there,

Does anyone know a simple way to schedule a DS job to run every 15 minutes?

I checked in the DS Director and it only allows once a day!
Am I seeing this right?

Thanks!
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

You can do this a couple of different ways...

1) This may not be obvious, but you can add a job to the scheduler more than once. So, you could schedule a job to run at 8:00 every day and at 8:15 every day, etc etc. That's alot of scheduling and not the way most people do it. (as far as I know, anywho)

2) Write a piece of job control that launches the job inside of a loop. Schedule the job to run at the time you want the first interation to run and then use the 'sleep' command inside the loop to control the time period between iterations. We pass in Sleep Time and Loop Count variables into our batches that need to do this in order to control the frequency and duration of the job 'on the fly' so to speak. For example, if you want to run every fifteen minutes from 8am to 5pm, set sleep time to 900 seconds and repeat 36 times. If I figured correctly, the last run would be at 5pm and then the loop would exit. You could also code in a methodology for getting out of the loop early. We (when needed) check for a 'stop file' of a certain name in a certain place that when seen exits the loop.

Hope this helps,

-craig
Post Reply