Last Time SQL Server Restarted

Posted by & filed under , , , , .

Not a really hard thing to figure out, but for some crazy reason I always forget.  So, hopefully actually writing it out for the world to see will help me remember.

Since tempdb is created every time that SQL Server restarts, the created date for that database can be used to determine the last time the SQL Server restarted.

SELECT create_date FROM sys.databases WHERE name = ‘tempdb

Yeah… really hard, hehe.