SQL Database Mail – User security to allow facility

 
Security > Logins > Pick Login > Properties > User Mapping > msdb > tick on
Database role membership include DatabaseMailUserRole
 
msdb has more database role memberships. May be resolution to LinkedServer issue. 
 
PROBLEM
Procedure sp_send_dbmail, line 141 profile name is not valid
 
SOLVED
 
EXECUTE msdb.dbo.sysmail_add_principalprofile_sp
    @principal_name = 'ApplicationUser',
    @profile_name = 'AdventureWorks2008R2 Administrator Profile',
    @is_default = 1 ;
 
 

Leave a comment