There are many ways to read error log from SQL Server.
Lets take an example: To find out "Error: 1443, Severity: 16, State: 2"
the best way is: input the results of XP_readerrorlog to a temparory table once the result of the errorlog gets in to the temporary table you need to put a where condition to get the desired output.
create table #temp1
(logdate datetime,- xp_readerrorlog
- SSMS->Management ->SQLServer Error Logs ->
Lets take an example: To find out "Error: 1443, Severity: 16, State: 2"
the best way is: input the results of XP_readerrorlog to a temparory table once the result of the errorlog gets in to the temporary table you need to put a where condition to get the desired output.
create table #temp1
processinfo varchar(100),
text_ varchar(1024)
)
insert #temp1exec xp_readerrorlog
select * from #temp1where text_ ='Error: 1443, Severity: 16, State: 2.'order by logdate asc
No comments:
Post a Comment