Friday, March 25, 2011

Query to Retrieve Uptime from a SQL Server


SELECT DATEDIFF(D, CrDate, GETDATE()) 'Days On Line'
FROM SysDatabases
WHERE Name = 'TempDb'

No comments:

Post a Comment