SELECT
CONVERT(DECIMAL(12,3),
SUM(user_object_reserved_page_count) / 128.)
AS [User Objects (MB)]
,CONVERT(DECIMAL(12,3),
SUM(internal_object_reserved_page_count) / 128.
) AS [Internal Objects (MB)]
,CONVERT(DECIMAL(12,3),
SUM(version_store_reserved_page_count) / 128.
) AS [Version Store (MB)]
,CONVERT(DECIMAL(12,3),
SUM(unallocated_extent_page_count) / 128.
) AS [Free Space (MB)]
FROM
tempdb.sys.dm_db_file_space_usage WITH (NOLOCK);
Categories:
Tags:
No responses yet