Is it possible to make task run only during specific time in ETL?

Neil 396 Reputation points
2020-10-08T15:43:01.27+00:00

In an SSIS Package which is working fine and executing every hour. I want to add a task to execute only for the batch which runs at 8am

Means I want to add and notification email task at particular hour only. Is this possible to check time and execute the flow else just continue to execute the ETL as normal.

I know i can create a separate ETL and scheduled it run, just trying to see if I can avoid one more ETL and one more job for this.

SSIS 2015 and SQL Server 2016 are the version I am using.

SQL Server Integration Services
SQL Server Integration Services
A Microsoft platform for building enterprise-level data integration and data transformations solutions.
2,560 questions
0 comments No comments
{count} votes

Accepted answer
  1. Monalv-MSFT 5,896 Reputation points
    2020-10-09T02:00:06.803+00:00

    Hi @Neil ,

    We can add an empty Sequence Container and a Send Mail Task, Data Flow Task.
    We can set the Precedence Constraint between Sequence Container and Send Mail Task.
    Please refer to the following pictures:
    31133-cf.png
    31104-precedenceconstraint.png
    31142-expressionbuilder.png

    Best Regards,
    Mona

    ----------

    If the answer is helpful, please click "Accept Answer" and upvote it.
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments

2 additional answers

Sort by: Most helpful
  1. Vaibhav Chaudhari 38,721 Reputation points
    2020-10-08T16:06:16.033+00:00

    Maybe try having some task that will give the time like Execute SQL task and run getdate() and get time part from it

    Add condition in precedent constraint - If time is 8 AM only then run the connected next task that you want to run.

    Not sure if it is really possible as you might have multiple tasks that you don't want run along


    Please don't forget to Accept Answer and Up-vote if the response helped -- Vaibhav

    1 person found this answer helpful.
    0 comments No comments

  2. Neil 396 Reputation points
    2020-10-09T11:50:48.307+00:00

    Thanks Vibhav and Monal, this looks good and it should work.
    I will build this and test.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.