How to send mail from Stored Procedure?

Manoj picture Manoj · Jul 5, 2010 · Viewed 15.3k times · Source

I need to send a mail from Stored Procedure. I knew it is possible. I studied it from this link . How do i authenticat in SMTP Server. Do you have any idea.?

Thanks

Answer

Marko picture Marko · Jul 5, 2010

You can use SQL Database Mail.

See Database Mail and SQL Mail Stored Procedures (Transact-SQL)

And here's a Tutorial