• Jeffrey Williams 3188 (5/2/2013)


    You need to also be aware that any explicit transactions - with explicit rollbacks will also roll back any of these messages that are being logged.

    To clarify, I think this pertains only to inserts into a custom log table from within T-SQL code but not to the setting in SQL Agent I described above that writes messages to msdb.dbo.sysjobsteplogs. SQL Agent will write to the log table whatever is sent to the error or info streams by the code in the job step regardless of the transactions being used in that code.

    There are no special teachers of virtue, because virtue is taught by the whole community.
    --Plato