Determine the Last Start Date for a SQL Server Instance
Today I had a friend on Facebook ask if I knew of a DMV or DMF that provided the date upon which the SQL Service was last started. What I use instead in any of my queries is the create date of the tempdb database. Why? Well simply put, tempdb is recreated each time the SQL Server service is started. Therefore, by querying sys.databases (or sys.sysdatabases) for the creation date of tempdb you can determine when the SQL Server service.
Either of the following queries work in SQL Server 2005 or 2008:
Very cool. SQL Mag finds the same information a different way. By asking when the login time of spid 1 was.
http://www.sqlmag.com/Article/ArticleID/21977/sql_server_21977.html
As expected, after checking, I see both results are typically less than a second apart.
By the way, I just found this MS connect item which I think deserves a lot more attention.
https://connect.microsoft.com/SQLServer/feedback/ViewFeedback.aspx?FeedbackID=316237
I agree with the MS Connect item and rated it up.