cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
jamesc
Engaged Sweeper
Hi,
I'm currently trying to create a report to list out computers, how can I filter by IP address, as the ip address has different length
Thanks
1 REPLY 1
MikeMc
Champion Sweeper II
Lansweeper uses an IPNumeric field to easily filter and sort IP addresses. The below sample lists all devices between 192.168.1.1 (192168001001) to 192.168.1.255 (192168001255).

Select Top 1000000 tblAssets.AssetID,
tblAssets.AssetName,
tblAssets.IPAddress
From tblAssets
Inner Join tblAssetCustom On tblAssetCustom.AssetID = tblAssets.AssetID
Where tblAssetCustom.State = 1 And tblAssets.IPNumeric >= 192168001001
And tblAssets.IPNumeric <= 192168001255
Order By tblAssets.IPNumeric