Hi, @Boopathi Subramaniam
Thank you for posting in Microsoft Q&A forum.
I think you are trying to get all DP's Disk Space Details, you may try the query like below:
SELECT DISTINCT UPPER(SUBSTRING(dp.ServerName, 1, CHARINDEX ('.', dp.ServerName) -1)) AS 'Distribution Point', SMSSiteCode AS 'Site Code', Description, sys.Resource_Domain_OR_Workgr0 AS 'Domain',
SUBSTRING(ss.SiteObject, CHARINDEX('$', ss.SiteObject) - 1, CHARINDEX('$\', ss.SiteObject) - CHARINDEX('$', ss.SiteObject) + 2) AS 'Volume',
ss.BytesTotal / 1048576 AS 'Total (GB)', ss.BytesFree / 1048576 AS 'Free (GB)', ss.PercentFree AS '% Free'
FROM vDistributionPoints AS dp LEFT OUTER JOIN
v_R_System AS sys ON (UPPER(SUBSTRING(dp.ServerName, 1, CHARINDEX ('.', dp.ServerName) -1)) = sys.Name0) RIGHT OUTER JOIN
vSummarizer_SiteSystem AS ss ON UPPER(SUBSTRING(ss.SiteSystem, CHARINDEX('\\', ss.SiteSystem) + 2, CHARINDEX('"]', ss.SiteSystem) - CHARINDEX('\\', ss.SiteSystem) - 3)) = dp.ServerName
WHERE ss.Role = 'SMS Distribution Point'
If the response is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.