1

I have a job on my server with email notification on success and failure. The mail notification has the subject as

[The job succeeded.] SQL Server Job System: 'XYZ' completed on \123.

or

[The job failed.] SQL Server Job System: 'XYZ' completed on \123.

Now I have migrated the job to another server but the mail notification is like

SQL Server Job System: 'XYZ' completed on \456.

Why does the subject not contain [The job succeeded.] or [The job failed.]? How to get it back in the subject line of email notification?

3
  • Nobody has the answer for this :( Commented Oct 19, 2012 at 9:05
  • I may be wrong, but I don't think I have ever seen succeeded or failed in the subject line itself, only completed. Is there any difference in the job definitions or other configuration between the servers? How exactly did you "migrate" the job to the second server? Commented Oct 19, 2012 at 15:33
  • I created the job script and did required changes. In the previous job as well, iwas not able to figure out whether this specific subject was mentioned somewhere. :( Commented Oct 31, 2012 at 6:12

1 Answer 1

1

The answer is probably the edition of SQL Server to which you migrated the job. I had the same issue between SQL Server 2008 R2 (NOT adding the job's status in the subject line) and SQL Server 2012 (DOES add the job's status in the status line). It appears that SQL Server 2012 improved on Database Mail emails. Thankfully, I found this link: http://shaunjstuart.com/archive/2012/12/another-sql-2012-improvement/

Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.