
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-02-2016 01:42 PM
IP Location (from Asset Groups Page)
Asset Name
OS Type (windows, linux, mac, basically all of them, with the OS Version if possible.)
IP Address
Domain
Address width (32 or 64)
Manufacturer
Model
Serial Number
Last Seen
I can get all the Operating systems, but not the IPLocation, or vice versa. I can't seem to get both. Once I get the IPLocations working right, all I get is windows systems.
I have right clicked the link between tblAssets and tsysOS to "Select all rows from tblAssets", and it doesn't seem to give me linux boxes too.
Last version of code I played with that gives me all assets :
Select Top 1000000 tblAssets.IPAddress,
tblAssets.AssetID,
tblAssets.AssetName,
tsysAssetTypes.AssetTypename As [Asset Type],
tsysAssetTypes.AssetTypeIcon10 As icon,
tblAssetCustom.Model,
tsysOS.OSname
From tblAssets
Inner Join tsysAssetTypes On tblAssets.Assettype = tsysAssetTypes.AssetType
Inner Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
Left Join tsysOS On tblAssets.OScode = tsysOS.OScode
Where tblAssetCustom.State = 1
Order By tblAssets.IPAddress,
tblAssets.AssetName Desc
Last version that I was able to use, that gives me IPLocations :
Select Top 1000000 tsysIPLocations.IPLocation,
tblAssets.AssetID,
tblAssets.AssetName,
tblProcessor.AddressWidth,
tblAssets.Domain,
tblAssets.Description,
tblAssets.Lastseen
From tblAssets
Left Join tsysIPLocations On tblAssets.IPNumeric >= tsysIPLocations.StartIP
And tblAssets.IPNumeric <= tsysIPLocations.EndIP
Inner Join tblProcessor On tblAssets.AssetID = tblProcessor.AssetID
Order By tsysIPLocations.IPLocation,
tblAssets.AssetName
This would be much easier if I could edit the reports in the dashboard under "IP Locations Overview" widget. Is that possible?
Thanks in advance!
Solved! Go to Solution.
- Labels:
-
Report Center

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-18-2016 06:10 PM

Anyway, here you go:
Select Distinct Top 1000000 tblAssets.AssetID,
tblAssets.AssetName,
tsysOS.OSname,
tblAssets.IPAddress,
tblAssets.Domain,
tblAssetCustom.Manufacturer,
tblAssetCustom.Model,
tblAssetCustom.Serialnumber,
tsysAssetTypes.AssetTypename As [Asset Type],
tsysAssetTypes.AssetTypeIcon10 As icon,
tblAssets.Lastseen,
tsysIPLocations.IPLocation,
tblProcessor.AddressWidth
From tblAssets
Inner Join tsysAssetTypes On tblAssets.Assettype = tsysAssetTypes.AssetType
Inner Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
Left Join tsysOS On tblAssets.OScode = tsysOS.OScode
Left Join tsysIPLocations On tblAssets.IPNumeric >= tsysIPLocations.StartIP
And tblAssets.IPNumeric <= tsysIPLocations.EndIP
Left Join tblProcessor On tblProcessor.AssetID = tblAssets.AssetID
Where tblAssetCustom.State = 1
Order By tblAssets.IPAddress,
tblAssets.AssetName Desc

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-18-2016 06:10 PM

Anyway, here you go:
Select Distinct Top 1000000 tblAssets.AssetID,
tblAssets.AssetName,
tsysOS.OSname,
tblAssets.IPAddress,
tblAssets.Domain,
tblAssetCustom.Manufacturer,
tblAssetCustom.Model,
tblAssetCustom.Serialnumber,
tsysAssetTypes.AssetTypename As [Asset Type],
tsysAssetTypes.AssetTypeIcon10 As icon,
tblAssets.Lastseen,
tsysIPLocations.IPLocation,
tblProcessor.AddressWidth
From tblAssets
Inner Join tsysAssetTypes On tblAssets.Assettype = tsysAssetTypes.AssetType
Inner Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
Left Join tsysOS On tblAssets.OScode = tsysOS.OScode
Left Join tsysIPLocations On tblAssets.IPNumeric >= tsysIPLocations.StartIP
And tblAssets.IPNumeric <= tsysIPLocations.EndIP
Left Join tblProcessor On tblProcessor.AssetID = tblAssets.AssetID
Where tblAssetCustom.State = 1
Order By tblAssets.IPAddress,
tblAssets.AssetName Desc

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-17-2016 01:26 PM
The code below reports on 7399 assets in my environment. It also includes monitors, printers, routers, phones, and switches. I don't mind having all that in the report, as I have to take it into excel to build the final reports for management anyway, and they're easy to hide with autofilter. I might need to show them in the future by site anyway, so I left it.
What I can't get with the code below, is the IPLocation to work.
When I add IPLocation in, I get 2600 assets. No monitors, printers, routers, phones, switches, etc... basically nothing but windows machines.
I'm amazed by what you can do with SQL Query. Do you know how to add IPLocation and Address width to this?
Select Top 1000000 tblAssets.AssetID,
tblAssets.AssetName,
tsysOS.OSname,
tblAssets.IPAddress,
tblAssets.Domain,
tblAssetCustom.Manufacturer,
tblAssetCustom.Model,
tblAssetCustom.Serialnumber,
tsysAssetTypes.AssetTypename As [Asset Type],
tsysAssetTypes.AssetTypeIcon10 As icon,
tblAssets.Lastseen
From tblAssets
Inner Join tsysAssetTypes On tblAssets.Assettype = tsysAssetTypes.AssetType
Inner Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
Left Join tsysOS On tblAssets.OScode = tsysOS.OScode
Where tblAssetCustom.State = 1
Order By tblAssets.IPAddress,
tblAssets.AssetName Desc
Thanks again!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-16-2016 10:28 PM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-16-2016 08:14 PM
Appreciate the attempt, though.

If anyone else knows how to do this, I'd appreciate it.
Been doing a lot of this lately :


- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-12-2016 10:11 PM
We don't really use Lansweeper for Linux scanning, so I doubt I can be much more help in that area.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-12-2016 10:01 PM
I'll noodle it a bit, and see if I can get them.
If you see a way before I do, great kudos.
Thanks Mike!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-12-2016 09:50 PM
Select Distinct Top 1000000 tsysIPLocations.IPLocation,
tblAssets.AssetID,
tblAssets.AssetName,
(Case When tblAssets.Assettype = -1 Then tblOperatingsystem.Caption
Else tblLinuxSystem.OSRelease End) As OSName,
(Case When tblAssets.Assettype = -1 Then tblAssets.OScode
Else tblLinuxSystem.KernelRelease End) As OSCode,
tblAssets.IPAddress,
tblAssets.Domain,
(Case
When tblAssets.Assettype =
-1 Then Convert(VARCHAR,tblProcessor.AddressWidth) Else 'Unknown'
End) As AddressWidth,
tblAssetCustom.Manufacturer,
tblAssetCustom.Model,
tblAssetCustom.Serialnumber,
tblAssets.Lastseen
From tblAssets
Inner Join tblAssetCustom On tblAssetCustom.AssetID = tblAssets.AssetID
Left Join tsysIPLocations On tblAssets.IPNumeric >= tsysIPLocations.StartIP
And tblAssets.IPNumeric <= tsysIPLocations.EndIP
Left Join tblOperatingsystem On tblOperatingsystem.AssetID = tblAssets.AssetID
Left Join tblLinuxSystem On tblLinuxSystem.AssetID = tblAssets.AssetID
Left Join tblProcessor On tblProcessor.AssetID = tblAssets.AssetID
Where tblAssetCustom.State = 1 And (tblAssets.Assettype = -1 Or
(tblAssets.Assettype = 11 And Exists(Select tblLinuxSystem.AssetID
From tblLinuxSystem Where tblLinuxSystem.AssetID = tblAssets.AssetID)))
Order By tsysIPLocations.IPLocation,
tblAssets.IPAddress

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-10-2016 01:31 PM
Thanks.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-04-2016 07:52 PM
