score:0

You can create an event handler onPostExecute of the pacakge and add the proc on an execute SQL Task in there

OR

add all your current components inside a sequence container and drag the green arrow to a new execute sql task component with your procedure. Double click the green arrow and select "Completion" instead of "Success"

score:0

OnPostExecute gets executed for every tasks. So this is not good for a requirement that expects OnPackageEnd kind of an event.

score:3

Well I think the simplest thing is to add the execution of the proc as a second step in the job that executes the package, you can specify there that you can go to the next step on failure as well as on success.

Or you put the Exec SQL task to execute the package at the end of the process (that gets the success branch) and put it in the event handler for all failures (we do the event handler at the package level not for individual steps), we do that for one step where we run the same proc but with different input values in case of failure or success.

score:5

In the package put all the tasks in a container. And below the container put the execute proceduer task and for precedence constraint choose values as "Completion"(The line will be in Blue color, green by default). So irrespective of the package status (success or fail) the stored proc will be executed.


More questions

More questions with similar tag