Hi all

I've got a number of scheduled tasks which run on our SQL2k5 server. At the present moment, I am forced to go into the server and manually check that the jobs have run properly.

I've managed to set up the email account, and tested it to ensure that it works. I've also created an Operator bearing my details, so that the system knows to send emails to me. However, when I set up one of my frequent tasks to send an email advising of the job's finishing status, it appears to do nothing. When I look at the database mail log, I can see the following error:

"[264] An attempt was made to send an email when no email session has been established."

I guess my main question would be this: what do I need to do to the scheduled job in order to get it to establish that email session before actually sending the mail?

TIA