0

I have been trying to create a package which executes a couple of dataflow tasks based on the available value in one of the variables. How can I achieve this?

The sample scenario: Variable param may have a string value "current" or "previous". If the user selects current then the data flow task A will get executed, else data flow task B will get executed.

I have two variables : 1) Param and 2) ParamValue. Using the script task If param=="current" then paramvalue would be 1, else if param=="previous" then paramvalue would be "Previous"

And in the precedence constraint added conditions to execute the data flow tasks. But its not working as expected.

mustaccio
28.7k24 gold badges60 silver badges77 bronze badges
asked Apr 17, 2019 at 19:48

1 Answer 1

1

Precedence constraints should be able to handle this requirement. Obviously without seeing the package and how you're setting up the constraints, we can't tell you why it isn't working. However, I've found that using an Expression for the Disable property of the data flow task can also be a good way to control flow. Maybe that will work better for you.

To do this, right-click on the data flow task and select Properties. Go to Expressions and click the ellipsis (...) to open the Property Expressions Editor. Under Property, select Disable, and under Expression, click the ellipsis again to open the Expression Builder. Then write the expression that determines if the data flow task should be disabled or not.

answered Apr 18, 2019 at 12:40

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.