Right, got this set up and working (it was actually a setting in McAfee that was blocking everything but that's now sorted).What I want to do now (if possible) is pass the query parameters for:-recipients - this will a semi-colon delimited listsubject - a short stringbody - a slightly longer stringThis is my query as it stands:-exec msdb.dbo.sp_send_dbmail @profile_name='Profile' ,@recipients = 'my email address' ,@subject = 'test from sql' ,@body = 'if you can see this SQL mail is working !!!!!'
I've edited the profile name and my email address for obvious reasons.Anyone any ideas how this can be done, or even if it's possible?