We currently use xp_smtp_sendmail to send the emails on a sql2000 32-bit box. We are trying to move our databases to a new sql2005 64-bit box. One solution is to replace xp_smtp_sendmail with database mail since xp_smtp_sendmail does not work on 64-bit box. The only problem is that we need to change the sender email dynamically based on the query results and I don't know how to accomplish this by using database mail. Does anyone have an idea? We are not restricted to database-mail solution though.
Thanks for help.
EXECUTE msdb.dbo.sysmail_update_account_sp
@.account_name = 'AdventureWorks Administrator',
@.email_address = 'dba@.Adventure-Works.com'
See SQL Server 2005 Books Online topic:
sysmail_update_account_sp (Transact-SQL)
http://msdn2.microsoft.com/fr-fr/library/ms188381.aspx
EXECUTE msdb.dbo.sysmail_update_account_sp
@.account_name = 'AdventureWorks Administrator',
@.email_address = 'dba@.Adventure-Works.com'
No comments:
Post a Comment