Yesterday I stumbled upon an example in article that used a search string in xp_readerrorlog. Hope all is well.įriday, Janu10:39:12 AM - Danette Riviello How can I retrieve teh TEXT field alone from this? I need to get the Server Manaufacturer from thsi query:ĮXEC sys.xp_readerrorlog 0, 1, N'Manufacturer' Wednesday, J12:45:48 PM - Clifton S Dunaway INSERT INTO #temp(LogDate, ProcessInfo, TextData)ĮXEC sp_readerrorlog 0, 1, N'Manufacturer' If the statistics are boring, you’ve got the wrong numbers.Ĭlifton, the only way to do that would be to load the data to a temp table and then pull the data you need.ĬREATE TABLE #temp ( LogDate datetime, ProcessInfo varchar(100), TextData varchar(max) ) This script will show all but logon issues:ĭROP TABLE IF EXISTS #SQLErrorLog -assuming SQL Server 2016+.otherwise use the typical if object exists drop We had a recovery of one of our biggest databases (> 100 TB) and logs were filled with logon issues due to thousands of connections not being able to connect. It's more flexible if you put everything in a temp table. This allows you to query the data much easier. How I can get this Result In SQL 2008 R2, SQL 20014, SQL 2016 Sir I want to Know Deleted record from specific Table with specific date period Tuesday, Decem11:32:41 AM - Mehwish Mushtaq Inamdar ![]() Tuesday, Decem11:56:25 AM - Greg Robidoux
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |