→ 🚀What's New? Join Us for the Fall Product Launch! Register Now !
‎08-18-2015 11:04 AM
Solved! Go to Solution.
‎08-18-2015 02:56 PM
Select Top 1000000 tblAssets.AssetID,
tblAssets.AssetName,
Case When tblComputersystem.Domainrole > 1 Then 'Server' Else Case
When Coalesce(tblPortableBattery.AssetID, 0) = 0 Then 'Desktop/Unknown'
Else 'Laptop' End End As Type,
tblOperatingsystem.Caption As OS,
tsysAssetTypes.AssetTypename,
tsysAssetTypes.AssetTypeIcon10 As icon,
tblAssets.IPAddress,
tsysIPLocations.IPLocation,
tblAssets.Lastseen,
tblAssets.Lasttried
From tblAssets
Inner Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
Inner Join tsysAssetTypes On tsysAssetTypes.AssetType = tblAssets.Assettype
Left Join tblComputersystem On tblAssets.AssetID = tblComputersystem.AssetID
Left Join tblOperatingsystem On tblAssets.AssetID = tblOperatingsystem.AssetID
Left Join tblPortableBattery On tblAssets.AssetID = tblPortableBattery.AssetID
Left Join tsysIPLocations On tblAssets.IPNumeric >= tsysIPLocations.StartIP
And tblAssets.IPNumeric <= tsysIPLocations.EndIP
Where tblAssetCustom.State = 1 And tsysAssetTypes.AssetType = -1
Order By tblAssets.Domain,
tblAssets.AssetName
‎08-18-2015 03:26 PM
‎08-18-2015 02:56 PM
Select Top 1000000 tblAssets.AssetID,
tblAssets.AssetName,
Case When tblComputersystem.Domainrole > 1 Then 'Server' Else Case
When Coalesce(tblPortableBattery.AssetID, 0) = 0 Then 'Desktop/Unknown'
Else 'Laptop' End End As Type,
tblOperatingsystem.Caption As OS,
tsysAssetTypes.AssetTypename,
tsysAssetTypes.AssetTypeIcon10 As icon,
tblAssets.IPAddress,
tsysIPLocations.IPLocation,
tblAssets.Lastseen,
tblAssets.Lasttried
From tblAssets
Inner Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
Inner Join tsysAssetTypes On tsysAssetTypes.AssetType = tblAssets.Assettype
Left Join tblComputersystem On tblAssets.AssetID = tblComputersystem.AssetID
Left Join tblOperatingsystem On tblAssets.AssetID = tblOperatingsystem.AssetID
Left Join tblPortableBattery On tblAssets.AssetID = tblPortableBattery.AssetID
Left Join tsysIPLocations On tblAssets.IPNumeric >= tsysIPLocations.StartIP
And tblAssets.IPNumeric <= tsysIPLocations.EndIP
Where tblAssetCustom.State = 1 And tsysAssetTypes.AssetType = -1
Order By tblAssets.Domain,
tblAssets.AssetName
Experience Lansweeper with your own data. Sign up now for a 14-day free trial.
Try Now