‎09-22-2020 08:37 PM
‎10-02-2020 09:24 PM
Select Top 1000000 tblAssets.AssetID,
tblAssets.AssetName,
tblAssets.Domain,
tblAssets.Username,
tblAssets.Userdomain,
Coalesce(tsysOS.Image, tsysAssetTypes.AssetTypeIcon10) As icon,
tblAssets.IPAddress,
tsysIPLocations.IPLocation,
tblAssetCustom.Manufacturer,
tblAssetCustom.Model,
tsysOS.OSname As OS,
tblAssets.SP,
tblAssets.LsAgentVersion,
tblAssets.Lastseen,
tblAssets.Lasttried
From tblAssets
Inner Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
Inner Join tsysAssetTypes On tsysAssetTypes.AssetType = tblAssets.Assettype
Inner Join tsysIPLocations On tsysIPLocations.LocationID =
tblAssets.LocationID
Inner Join tblState On tblState.State = tblAssetCustom.State
Left Join tsysOS On tsysOS.OScode = tblAssets.OScode
Where tsysOS.OSname Like 'Win%' And tblAssets.LsAgentVersion Is Not Null And
tblAssets.LsAgentVersion < '7.2.110.18' And tblState.Statename = 'Active'
Order By tblAssets.Domain,
tblAssets.AssetName
‎10-02-2020 06:50 PM
SELECT Top 1000000 tblAssets.AssetID,
tsysOS.Image AS icon,
tblASsets.ASsetUnique,
tblOperatingsystem.Caption AS [Operating System],
tblADusers.Displayname AS [User],
tblSoftware.softwareVersion AS [LsAgent Version],
tblASsets.IPAddress AS [IP Address],
tblASsets.LAStseen AS [Last Seen],
tblASsets.LASttried AS [Last Tried]
FROM tblSoftware
INNER JOIN tblASsets ON tblSoftware.ASsetID = tblASsets.ASsetID
INNER JOIN tblOperatingsystem ON tblASsets.ASsetID = tblOperatingsystem.ASsetID
INNER JOIN tblComputersystem ON tblASsets.ASsetID = tblComputersystem.ASsetID
INNER JOIN tblSoftwareUni ON tblSoftware.softID = tblSoftwareUni.SoftID
INNER JOIN tblASsetCustom ON tblASsets.ASsetID = tblASsetCustom.ASsetID
INNER JOIN tsysOS ON tblASsets.OScode = tsysOS.OScode
INNER JOIN tblADComputers ON tblASsets.ASsetID = tblADComputers.ASsetID
LEFT JOIN tblADusers ON tblASsets.Username = tblADusers.Username
WHERE tblSoftwareUni.softwareName LIKE '%LsAgent%' AND tblSoftware.softwareVersion < '7.2.110.18' AND tblASsetCustom.State = 1
ORDER BY tblASsets.ASsetName
Experience Lansweeper with your own data. Sign up now for a 14-day free trial.
Try Now