Friday, May 06, 2011

Database created date and sql server restarted time

Running the below query you can see the databases created date and time


select name, crdate from sys.sysdatabases order by crdate

Also you can run the below query to find the sql server last time restarted.

select name, crdate from sys.sysdatabases WHERE name = 'tempdb'