View all Database File Sizes

SELECT s_mf.[name], s_mf.physical_name, s_mf.[size]/128 AS SizeInMB, s_mf.max_size/128 AS MaxSizeInMB, s_mf.growth
FROM sys.master_files s_mf
ORDER BY s_mf.[size] DESC

Above query will return Database Name, its physical path & database files size in MB.

Happy Coding !!

No comments: