If I am in the wrong sub-forum, please let me know where I belong. I submitted this issue to this sub, b/c I believe I have an accessibility issue.
I have a maintenance place that executes a stored proc. The stored proc is as followings:
CREATE PROCEDURE spFirst
@Err AS INT = -1
EXEC @Err = xp_cmdshell 'dir C:\temp\*.exe'
EXEC msdb.dbo.sp_send_dbmail @profile_name = 'Mail_Proj',
@recipients = 'email@example.com',
@body = 'Complete',
@subject = 'Dir Listing'
The proc runs successfully and when done, I always get an email message in my Inbox, as expected. When the proc is executed directly from the maintenance plan, it still runs successfully, and the email message is successfully received in my Inbox.
A SQL Job was setup to run the maintenance plan. The history of the job indicates that it is completing successfully, but this cannot be true, as my inbox never receives the expected email
View Complete Post