xp_readerrrorlog
It is an undocumented extended stored procedure with at least 7 parameters (default null), that calls a dll to show results.
Parameters details as:
- Value of error log file you want to read: 0 = current, 1 = Archive #1, 2 = Archive #2, etc...
- Log file type: 1 or NULL = error log, 2 = SQL Agent log
- Search string 1: String one you want to search for
- Search string 2: String two you want to search for to further refine the results
- ? - Unknown
- ? - Unknown
- Sort order for results: N'asc' = ascending, N'desc' = descending
Example:
xp_readerrorlog 0, 2, 'ODBC', 'SQL Server',Null, Null , N'ASC'
LogDate ErrorLevel Text
2008-11-23 07:17:55.000 3 [102] SQL Server ODBC driver version 9.00.3042
No comments:
Post a Comment