Wednesday, March 21, 2012

Creating a SQL Log file in Event Viewer

I believe I have seen this done or at least read about it, in any event how
can a person setup the Windows Event Viewer log to monitor and log specific
events in a speficic SQL database?
TIABryan,
SQL Server can be configured to write error messages to the event log. See:
SP_ADDMESSAGE and RAISERROR (WITH LOG) in the SQL Server Books Online. You
can also use xp_logevent and write job status's in the log as well.
HTH
Jerry
"Bryan.S.Walker" <BryanSWalker@.discussions.microsoft.com> wrote in message
news:E400E837-5B3E-43BC-B146-F3FA0DEE6462@.microsoft.com...
>I believe I have seen this done or at least read about it, in any event how
> can a person setup the Windows Event Viewer log to monitor and log
> specific
> events in a speficic SQL database?
> TIA

No comments:

Post a Comment