July 9, 2015 at 8:11 am
Hi all,
Now Im trying to schedule a ssis job run from 12th business day to 20th business day for every month.
(The package should run 12th-20th everyday).
Can anyone tell me how to do this in sql job agent.?
Thanks
July 9, 2015 at 9:28 am
caojunhe24 (7/9/2015)
Hi all,Now Im trying to schedule a ssis job run from 12th business day to 20th business day for every month.
(The package should run 12th-20th everyday).
Can anyone tell me how to do this in sql job agent.?
Thanks
Can't see an elegant way. Though there are workarounds:
1) Create (9) monthly schedules against the job.
2) Run the package every day, but build logic in the package to avoid all processing unless it's a 12–20 day.
The absence of evidence is not evidence of absence.
Martin Rees
You can lead a horse to water, but a pencil must be lead.
Stan Laurel
July 9, 2015 at 9:40 am
Phil Parkin (7/9/2015)
caojunhe24 (7/9/2015)
Hi all,Now Im trying to schedule a ssis job run from 12th business day to 20th business day for every month.
(The package should run 12th-20th everyday).
Can anyone tell me how to do this in sql job agent.?
Thanks
Can't see an elegant way. Though there are workarounds:
1) Create (9) monthly schedules against the job.
2) Run the package every day, but build logic in the package to avoid all processing unless it's a 12–20 day.
I agree with running it everyday. It's what I would do.
For best practices on asking questions, please read the following article: Forum Etiquette: How to post data/code on a forum to get the best help[/url]
July 9, 2015 at 9:59 am
Thank you for your reply.
The problem is this job should scheduled on 12th-20th business day. not a normal 12th-20th which means for every month these business days are gonna changed.
July 9, 2015 at 10:23 am
caojunhe24 (7/9/2015)
Thank you for your reply.The problem is this job should scheduled on 12th-20th business day. not a normal 12th-20th which means for every month these business days are gonna changed.
We understand that. You need to add the logic in the SSIS package to determine if the current day is a business day.
It's simple to get the day of the week for any date by using the SQL DatePart, so that solves part of the problem.
If I were doing this, I would probably use some sort of Date table, or my date dimension, to check if the current day is a business day or not. In building such a table you can take into account if it is a weekday or not, as well as if it is a holiday or not. You can also include in this table, which business day of the month it is.
For best practices on asking questions, please read the following article: Forum Etiquette: How to post data/code on a forum to get the best help[/url]
Viewing 5 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply