cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Facilities
Engaged Sweeper III
Hi

I am trying to get a list of all of the computers in the Lansweeper database and determine the last time that they were scanned. I am running this report:

Select Top 1000000 tblAssetCustom.Custom1 As FullName,
tblAssets.AssetID,
tblAssets.AssetUnique,
tblAssets.Domain,
tsysOS.OSname,
tsysOS.Image As icon,
tblAssets.Lastseen,
tsysIPLocations.IPLocation,
tblAssets.IPAddress As IP
From tblAssets
Inner Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
Inner Join tsysOS On tblAssets.OScode = tsysOS.OScode
Left Outer Join tsysIPLocations On tblAssets.IPNumeric >=
tsysIPLocations.StartIP And tblAssets.IPNumeric <= tsysIPLocations.EndIP
Where tblAssets.IPAddress <> '' And tblAssetCustom.State = 1
Order By tblAssets.IPNumeric

The report works well but it only gives me all of the widows devices, it excludes the Linux and Apple devices.
Any idea as to how they can be included in the report?

Regards
Nick
1 ACCEPTED SOLUTION
Nick_VDB
Champion Sweeper III
Instructions for adding this report to your Lansweeper installation can be found here. If you are interested in building or modifying reports, we do recommend:
  • Reviewing some SQL tutorials, as the Lansweeper report builder is a standard SQL editor. If you know SQL, you know how to build Lansweeper reports as well. This seems like a good tutorial.
  • Making use of our database dictionary, which explains in great detail what each database table and field stores. More information on the dictionary can be found here.
Select Top 1000000 tblAssetCustom.Custom1 As FullName,
tblAssets.AssetID,
tblAssets.AssetUnique,
tsysAssetTypes.AssetTypename,
tblAssets.Domain,
tsysOS.OSname,
Coalesce(tsysOS.Image, tsysAssetTypes.AssetTypeIcon10) As icon,
tblAssets.Lastseen,
tsysIPLocations.IPLocation,
tblAssets.IPAddress As IP
From tblAssets
Inner Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
Left Join tsysOS On tblAssets.OScode = tsysOS.OScode
Left Outer Join tsysIPLocations On tblAssets.IPNumeric >=
tsysIPLocations.StartIP And tblAssets.IPNumeric <= tsysIPLocations.EndIP
Inner Join tsysAssetTypes On tsysAssetTypes.AssetType = tblAssets.Assettype
Where (tsysAssetTypes.AssetTypename = 'Windows' Or
tsysAssetTypes.AssetTypename = 'Linux' Or tsysAssetTypes.AssetTypename =
'Apple Mac') And tblAssets.IPAddress <> '' And tblAssetCustom.State = 1
Order By tblAssets.IPNumeric

View solution in original post

1 REPLY 1
Nick_VDB
Champion Sweeper III
Instructions for adding this report to your Lansweeper installation can be found here. If you are interested in building or modifying reports, we do recommend:
  • Reviewing some SQL tutorials, as the Lansweeper report builder is a standard SQL editor. If you know SQL, you know how to build Lansweeper reports as well. This seems like a good tutorial.
  • Making use of our database dictionary, which explains in great detail what each database table and field stores. More information on the dictionary can be found here.
Select Top 1000000 tblAssetCustom.Custom1 As FullName,
tblAssets.AssetID,
tblAssets.AssetUnique,
tsysAssetTypes.AssetTypename,
tblAssets.Domain,
tsysOS.OSname,
Coalesce(tsysOS.Image, tsysAssetTypes.AssetTypeIcon10) As icon,
tblAssets.Lastseen,
tsysIPLocations.IPLocation,
tblAssets.IPAddress As IP
From tblAssets
Inner Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
Left Join tsysOS On tblAssets.OScode = tsysOS.OScode
Left Outer Join tsysIPLocations On tblAssets.IPNumeric >=
tsysIPLocations.StartIP And tblAssets.IPNumeric <= tsysIPLocations.EndIP
Inner Join tsysAssetTypes On tsysAssetTypes.AssetType = tblAssets.Assettype
Where (tsysAssetTypes.AssetTypename = 'Windows' Or
tsysAssetTypes.AssetTypename = 'Linux' Or tsysAssetTypes.AssetTypename =
'Apple Mac') And tblAssets.IPAddress <> '' And tblAssetCustom.State = 1
Order By tblAssets.IPNumeric