I have tried the below to try and mash some of the things I found on the Lansweeper site together, but to no avail, any advice is gratefully received
Select Top 1000000 tblAssets.AssetID,
tblAssets.AssetUnique,
tsysOS.OSname,
tblAssets.Description,
tblDiskdrives.Caption,
Cast(Cast(tblDiskdrives.Freespace As bigint) / 1024 / 1024 As numeric) As
free,
Cast(Cast(tblDiskdrives.Size As bigint) / 1024 / 1024 As numeric) As
[total size],
Ceiling((tblDiskdrives.Size - tblDiskdrives.Freespace) /
(Case tblDiskdrives.Size
When 0 Then 1
Else tblDiskdrives.Size
End) * 100) As UsedPCT,
tblDiskdrives.Lastchanged As [last changed],
tsysOS.Image As icon,
tblAssets.OScode
From tblAssets
Inner Join tblDiskdrives On tblAssets.AssetID = tblDiskdrives.AssetID
Inner Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
Inner Join tsysOS On...