How can I NOT send an email when there is no output?
I run several different data quality checks on our database. Different people receive the emailed notices. But unless there in something to report, I do not want an email to be sent. I worked out a way using the Block Until Done and Test tools, but this method relies on an error being generated before the email can be sent, which gets messy when actual workflow errors occur and I need to be notified of those.
Is there a way to both (1) not send an email when there is no output, and (2) but still get an email if there's an actual workflow error?
Solved! Go to Solution.
Here's one idea:
When Output File empty send email to say No Records Found using Report Text tool
a few other links:
email the attachment only when the attachment has data in it
Sending emails based on conditions
Send email - using Email tool or using After Run Event Email
Chris
I would continue to use the event driven emails for your error alerts, and play around with the email tool for your output.
Make sure the body and email address are driven from data fields, this way, if there are no rows of data feeding the email tool, no email will be sent, but also there will be no error generated.
There's a discussion with a similar example in this post that may be applicable.