database integrity check - email notification with query results?

  • I have db integrity check jobs set up using the statement below. I set the sql job to notify me upon completion or failure using notifications.

    The jobs always succeeds, but I am looking for a way to include the results of the sql statement in the body of my email notification.

    Any suggestions?

    USE [MyDB]

    DBCC CHECKDB(N'MyDB') WITH ALL_ERRORMSGS

  • see this post bu Gianluca, and his crosspost to his blog;

    it does exactlyt what you are after:

    http://www.sqlservercentral.com/Forums/FindPost1212804.aspx

    by coincidence, he jsut updated that older thread.

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • Very nice - Thank you!

Viewing 3 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply