In sql server 2005, I'm getting the error below when trying to run a sproc. The sproc doesn't reference mail and I'm not sure why this happens. I have the same db on another server that doesn't throw this error. What might be causing this?
Msg 15281, Level 16, State 1, Procedure sp_send_dbmail, Line 0
SQL Server blocked access to procedure 'dbo.sp_send_dbmail' of component 'Database Mail XPs' because this component is turned off as part of the security configuration for this server. A system administrator can enable the use of 'Database Mail XPs' by using sp_configure. For more information about enabling 'Database Mail XPs', see "Surface Area Configuration" in SQL Server Books Online.
The error message already indicates what you need to so, go to Surface Area Configuration and enable it.
start\Programs\SQL Server 2005\Configuration Tools\Surface Area..
Bottom link "for features"
Pick "database mail" from the left tree, on the right, click tick "Enable.."