List All Databases
-
Posted on July 2, 2010 by Derek Dieter
-
0
To list all databases in a SQL Server instance, run the following:
[cc lang=”sql”]
SELECT *
FROM sys.sysdatabases
[/cc]
This also outputs metadata about each database including createdate, compatibility level, and the MDF filename.
Post a comment
- Comments (RSS)
- Trackback
- Permalink