→ 🚀What's New? Explore Lansweeper's Fall 2024 Updates! Fall Launch Blog !
‎07-04-2013 03:53 PM
Solved! Go to Solution.
‎07-26-2013 04:16 PM
Select Top 1000000 tblAssets.AssetID,
tblAssets.AssetUnique,
tblAssets.Domain,
tsysOS.OSname,
tblAssetCustom.Manufacturer,
tblAssetCustom.Model,
tblAssets.Memory,
tblAssets.Processor,
tblState.Statename As State,
tsysIPLocations.IPLocation,
tblAssetCustom.Serialnumber As Serial,
tblAssets.Firstseen,
tblAssets.Username,
tblAssetCustom.PurchaseDate,
tblAssetCustom.Warrantydate,
tblDiskdrives.Caption As Drive,
tblDiskdrives.Volumename,
Cast(Cast(tblDiskdrives.Freespace As bigint) / 1024 / 1024 As numeric) As
FreeMB,
Cast(Cast(tblDiskdrives.Size As bigint) / 1024 / 1024 As numeric) -
Cast(Cast(tblDiskdrives.Freespace As bigint) / 1024 / 1024 As numeric) As
UsedMB,
Cast(Cast(tblDiskdrives.Size As bigint) / 1024 / 1024 As numeric) As TotalMB,
Floor(tblDiskdrives.Freespace / (Case tblDiskdrives.Size When 0 Then 1
Else tblDiskdrives.Size End) * 100) As FreePCT,
Ceiling((tblDiskdrives.Size - tblDiskdrives.Freespace) /
(Case tblDiskdrives.Size When 0 Then 1 Else tblDiskdrives.Size
End) * 100) As UsedPCT,
tblAssets.IPAddress,
tblAssets.Mac,
tsysOS.Image As icon
From tblAssets
Inner Join tblDiskdrives On tblAssets.AssetID = tblDiskdrives.AssetID
Left Outer Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
Inner Join tsysOS On tblAssets.OScode = tsysOS.OScode
Inner Join tsysAssetTypes On tsysAssetTypes.AssetType = tblAssets.Assettype
Inner Join tsysIPLocations On tblAssets.IPNumeric >= tsysIPLocations.StartIP
And tblAssets.IPNumeric <= tsysIPLocations.EndIP
Inner Join tblState On tblState.State = tblAssetCustom.State
Where Cast(Cast(tblDiskdrives.Size As bigint) / 1024 / 1024 As numeric) Is Not
Null And tblDiskdrives.DriveType = 3
Order By tblAssets.Domain,
tblAssets.AssetUnique,
Drive
‎07-26-2013 04:16 PM
Select Top 1000000 tblAssets.AssetID,
tblAssets.AssetUnique,
tblAssets.Domain,
tsysOS.OSname,
tblAssetCustom.Manufacturer,
tblAssetCustom.Model,
tblAssets.Memory,
tblAssets.Processor,
tblState.Statename As State,
tsysIPLocations.IPLocation,
tblAssetCustom.Serialnumber As Serial,
tblAssets.Firstseen,
tblAssets.Username,
tblAssetCustom.PurchaseDate,
tblAssetCustom.Warrantydate,
tblDiskdrives.Caption As Drive,
tblDiskdrives.Volumename,
Cast(Cast(tblDiskdrives.Freespace As bigint) / 1024 / 1024 As numeric) As
FreeMB,
Cast(Cast(tblDiskdrives.Size As bigint) / 1024 / 1024 As numeric) -
Cast(Cast(tblDiskdrives.Freespace As bigint) / 1024 / 1024 As numeric) As
UsedMB,
Cast(Cast(tblDiskdrives.Size As bigint) / 1024 / 1024 As numeric) As TotalMB,
Floor(tblDiskdrives.Freespace / (Case tblDiskdrives.Size When 0 Then 1
Else tblDiskdrives.Size End) * 100) As FreePCT,
Ceiling((tblDiskdrives.Size - tblDiskdrives.Freespace) /
(Case tblDiskdrives.Size When 0 Then 1 Else tblDiskdrives.Size
End) * 100) As UsedPCT,
tblAssets.IPAddress,
tblAssets.Mac,
tsysOS.Image As icon
From tblAssets
Inner Join tblDiskdrives On tblAssets.AssetID = tblDiskdrives.AssetID
Left Outer Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
Inner Join tsysOS On tblAssets.OScode = tsysOS.OScode
Inner Join tsysAssetTypes On tsysAssetTypes.AssetType = tblAssets.Assettype
Inner Join tsysIPLocations On tblAssets.IPNumeric >= tsysIPLocations.StartIP
And tblAssets.IPNumeric <= tsysIPLocations.EndIP
Inner Join tblState On tblState.State = tblAssetCustom.State
Where Cast(Cast(tblDiskdrives.Size As bigint) / 1024 / 1024 As numeric) Is Not
Null And tblDiskdrives.DriveType = 3
Order By tblAssets.Domain,
tblAssets.AssetUnique,
Drive
‎07-25-2013 05:56 PM
‎07-09-2013 09:33 PM
‎07-05-2013 11:47 AM
‎07-04-2013 09:06 PM
Experience Lansweeper with your own data. Sign up now for a 14-day free trial.
Try Now