Friday 19 April 2013

How to list all database files in SQL Server

To list all database files in SQL Server 2005 or 2008, we should use the view sys.master_files:

SELECT name, physical_name AS current_file_location
FROM master.sys.master_files

No comments:

Post a Comment