SSIS Send Mail Task Useless Error messages

January 7th, 2009 § 3 comments § permalink

I have spent ages trying to figure out why I am getting this adequately useless error message:

Error: 0xC002F304 at Send Mail Task, Send Mail Task: An error occurred with the following error message: “Failure sending mail.”.
Task failed: Send Mail Task

Msdn provides a list of Integration services error and warning message definitions here, but check out the definition for this one:

DTS_E_ERROROCCURREDWITHFOLLOWINGMESSAGE An error occurred with the following error message: “%1″.

Wow.. an error occured with the following message, failure sending mail, so amazingly descriptive.

Anyway you know you are doing something severely wrong when you do a google search on SMTP Error: 0xC002F304 and only get back about 2 releveant results, and sure enough I was doing something majorly wrong.  Eventually I got so frustrated with the Send Mail task and its complete lack of error debugging information I decided to use the script task to see if that would give me any more.

So I added a new script task and ew put some VB code in and that gave me a different error that was no more descriptive than the last. Anyway that motivated me to open Visual Studio and try the same in goold old C# and sure enough…

sendmaill

My SMTP server was unable to relay to the recipient I had chosen (my personal email). Switched it to my work email and BOOYA all go.

Where am I?

You are currently viewing the archives for Wednesday, January 7th, 2009 at laurasaur.