1

I have 4 jobs that extract some data from a source to be triggered sequentially at around 10 PM daily. The date to be used on all these jobs are same.

Currently, the run_date is being passed using a system_date function in each of these jobs. All fine if all the 4 jobs managed to complete within 2 hours, ie, before the date changes. But if any of the initial jobs get delayed and the later jobs triggered on the next day, as the system_date function return the next day's date. Whereas they were also expected to run as per the first jobs run_date in the series.

How can I achieve this? Is there any way can we the date from the scheduler level so that it can be used across all the tasks in that series.

I have done this using Control-M, but I am looking for an option in Windows Task Scheduler. Please share your thoughts if any.

Thanks, KPK

KPK
  • 11
  • 2

1 Answers1

0

try storing the date as a fixed variable at the start of the commands,

$date = get-date
ben mazor
  • 41
  • 2
  • 9
  • I am not calling all Task in one script. All 4 jobs are scheduled as separate Tasks. So how can I pass that common date across different tasks in Windows Task Scheduler. – KPK Oct 30 '18 at 15:51