Stop execution of remaining tasks
I have 2 tasks, a SCRIPT and a DATA FLOW. The script moves an existing file and the data flow re-creates the file based on new data from the SQL server. I want to add a task that would check if there is data from the SQL server table before the SCRIPT and DATA FLOW. If there is no data, then the SCRIPT and DATA FLOW will not run. Thinking of adding a SQL TASK to check records and a record counter into a variable. The variable will trigger the run on the SCRIPT and DATAFLOW. Any ideas on how I should handle it? TIA
May 30th, 2012 5:19pm

This is possible to achieve using a proper Precedence Constraint. I will point you to an article that will help you do that: http://www.simple-talk.com/sql/ssis/working-with-precedence-constraints-in-sql-server-integration-services/ See how execute SQL Task got branched in there.Arthur My Blog
Free Windows Admin Tool Kit Click here and download it now
May 30th, 2012 5:28pm

With a SQL task (SELECT COUNT bla bla bla), get the COUNT into a variable. Connect SQL Task with your SCRIPT doble click on green arrow :) Set precedence as: Evaluation Operation: Expression and Constraint Value: Success Expression: @[User::ROWCOUNT] > 0 Logical AND option must be selected. RUN The package "Im the light of the world, no follower of mine shall walk in darkness"
May 30th, 2012 5:46pm

With a SQL task (SELECT COUNT bla bla bla), get the COUNT into a variable. Connect SQL Task with your SCRIPT doble click on green arrow :) Set precedence as: Evaluation Operation: Expression and Constraint Value: Success Expression: @[User::ROWCOUNT] > 0 Logical AND option must be selected. RUN The package "Im the light of the world, no follower of mine shall walk in darkness"
Free Windows Admin Tool Kit Click here and download it now
May 30th, 2012 6:04pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics