Page 1 of 1

Schedule a job for working day of the month

Posted: 12 May 2013 1:37
by cheli
I want to schedule a job to run every 16th of the month, but if it is Saturday or Sunday then it should run on Monday. Can somebody help me to do it without defining a new calendar.

Without calendar

Posted: 15 May 2013 6:05
by th_alejandro
It's more efficient using a Calendar in this case. :D

But other ideas :

- Create a script that depends of 'dates' to run this job in a text file. Ex:
01-16-2013
02-18-2013 (02-16-2013 is saturday)
03-18-2013 (03-16-2013 is saturday)
04-16-2013
05-16-2013
06-17-2012 (06-16-2013 is sunday)
..
...

Then, create a function in the script. that evaluate current date vs dates in the text file. So, if this dates are equal, run the job.

Your process must run every day, but the initial script check for date and determine if the job really run or not on that date. 8O

Posted: 16 May 2013 4:23
by matom
Hi cheli,

If a workday calendar (Sat & Sun non business days) was available:
Month Days: 16 (Do not fill calendar field)
Confirmation Calendar : WorkDaysCal Shift : Next Day

Regards