SSIS Script Post Execute Problems

  • I have two paths out of a dataflow lookup transformation that are connected to script components. Each script component sets the value of a variable scoped to the top level control flow. I assumed that, based on the result of the lookup, only one of the scripts executes, but that is only partially true. The post executes for all scripts run regardless of the result of the lookup. Very annoying.

  • You need to add a precedence constraint to each of your script tasks to determine which one should run depending on the outcome of your variable from your script task.

  • It's more complicated than that. In the data flow, regardless of the constraint (lookup match, lookup no match, lookup error) the post executes for all three scripts connected to the look up will execute. The InputRow0 block of unexecuted scripts do not run, but the post executes do. I did find a way to program around this in the data flow and set the global variable correctly and I use the variable in constraints in the control flow to determine what task in the control flow to execute next. The problem was setting the variable correctly in the control flow.

Viewing 3 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply