Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
cidr
Posting Yak Master
207 Posts |
Posted - 2014-09-09 : 05:13:14
|
Hi,Quick question, hope someone can help. I have multiple sequence containers in my package. I only want to have one sendmail task for the failure/completion of the package. If I put the sendmail task in the last sequence container and the first seqence fails, the sendmail task will not be reached and therefore, no email will be sent out.Is there a way to have one sendmail task for all the sequence containers and allow it to send mail regardless of what sequence fails/completes?Many thanksP |
|
MichaelJSQL
Constraint Violating Yak Guru
252 Posts |
Posted - 2014-09-09 : 06:52:47
|
You could create some variables for a mail message. You could then set error precedence for each sequence to a task that would set the variables whenever an error occurs and route them to the one send mail task. You could either set them by default so state success so that whenever you reach the end of you code successfully the email would be sent with the success message or, if you do not like the default idea, you could simply set the variable to success before you currently send the email. You could also use events and do something similar using OnVariableValueChanged or onerror. |
|
|
|
|
|