Link to home
Start Free TrialLog in
Avatar of Alex A
Alex A

asked on

SQL Server: error when using sp_send_dbmail


Msg 22050, Level 16, State 1, Line 27
Failed to initialize sqlcmd library with error number -2147467259.

why can't I send email using sp_send_dbmail  ?

how to add myself to existing @profile_name ?

Thank you.

Avatar of Pavel Celba
Pavel Celba
Flag of Czechia image

Does your user have access rights to the msdb ?  Look at the datbase - Security - Users and check whether your user has "DatabaseMailUserRole" and "db_owner" under "Membership" and also have Alter, Control and Execute for the stored procedure created to send the mail.

Avatar of Peter Chan
Peter Chan
Flag of Hong Kong image

Link to home
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Alex A
Alex A