→ 🚀What's New? Join Us for the Fall Product Launch! Register Now !
‎08-19-2014 06:52 PM
Solved! Go to Solution.
‎05-23-2018 01:36 PM
Select Top (1000000) tsysOS.Image As icon,
tblAssets.AssetID,
tblAssets.AssetName,
tblAssets.Domain,
tblAssets.Username,
tblAssets.Userdomain,
tblAssets.IPAddress,
tblAssets.Firstseen,
tblAssets.Lastseen,
tblFloppy.Model,
tblAssetCustom.State
From tblFloppy
Inner Join tblAssets On tblFloppy.AssetID = tblAssets.AssetID
Inner Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
Inner Join tsysOS On tblAssets.OScode = tsysOS.OScode
Where (dbo.tblFloppy.Model Like N'%SSD%') Or
(dbo.tblFloppy.Model Like N'%solid%state%' And Not (dbo.tblAssets.Lastseen Is
Null) And dbo.tblAssetCustom.State = 1)
Select Top (1000000) tsysOS.Image As icon,
tblAssets.AssetID,
tblAssets.AssetName,
tblAssets.Domain,
tblAssets.Username,
tblAssets.Userdomain,
tblAssets.IPAddress,
tblAssets.Firstseen,
tblAssets.Lastseen,
tblFloppy.Model,
tblAssetCustom.State
From tblFloppy
Inner Join tblAssets On tblFloppy.AssetID = tblAssets.AssetID
Inner Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
Inner Join tsysOS On tblAssets.OScode = tsysOS.OScode
Where Not (dbo.tblFloppy.Model Like N'%SSD%') And Not (dbo.tblFloppy.Model Like
N'%solid%state%') And Not (dbo.tblFloppy.Model Like N'%OCZ%') And
Not (dbo.tblFloppy.Model Like N'%solid%state%') And
Not (dbo.tblFloppy.Model Like N'%SV300%') And Not (dbo.tblFloppy.Model Like
N'%Sandisk X%') And Not (dbo.tblFloppy.Model Like N'%Samsung SSD%') And
Not (dbo.tblFloppy.Model Like N'%Intel SSD%') And
Not (dbo.tblFloppy.Model Like N'%solid%state%') And
Not (dbo.tblFloppy.Model Like N'%SAMSUNG MZ%') And
Not (dbo.tblFloppy.Model Like N'%Virtual%') And Not (dbo.tblFloppy.Model Like
N'%LITEON LCH%') And Not (dbo.tblFloppy.Model Like N'%Dell%') And
Not (dbo.tblFloppy.Model Like N'%RAID%') And Not (dbo.tblFloppy.Model Like
N'%SanDisk SD%') And Not (dbo.tblFloppy.Model Like N'%SAMSUNG KU%') And
Not (dbo.tblFloppy.Model Like N'%LITEONIT LCS%') And
Not (dbo.tblFloppy.Model Like N'%MTFDDAK128MAY%') And
Not (dbo.tblFloppy.Model Like N'%Intel MegaSR%') And
Not (dbo.tblFloppy.Model Like N'%Generic%') And Not (dbo.tblFloppy.Model Like
N'%Micron 1100%') And Not (dbo.tblFloppy.Model Like N'%KINGSTON SKC%') And
Not (dbo.tblFloppy.Model Like N'%THNSN%') And Not (dbo.tblFloppy.Model Like
N'%External%') And Not (dbo.tblFloppy.Model Like N'%Expansion%') And
Not (dbo.tblFloppy.Model Like N'%USB%') And Not (dbo.tblFloppy.Model
Like N'%LSI%') And Not (dbo.tblFloppy.Model Like N'%Microsoft Storage Space%')
And Not (dbo.tblFloppy.Model Like N'%Kingston S10032%') And
Not (dbo.tblFloppy.Model Like N'%asmedia ASMT%') And
Not (dbo.tblAssets.Lastseen Is Null) And dbo.tblAssetCustom.State = 1
‎05-17-2019 07:21 PM
‎08-21-2014 04:00 PM
Select Top 1000000 tsysOS.Image As icon,
tblAssets.AssetID,
tblAssets.AssetName,
tblAssets.Domain,
tblAssets.Username,
tblAssets.Userdomain,
tblAssets.IPAddress,
tblAssets.Firstseen,
tblAssets.Lastseen
From tblAssets
Inner Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
Inner Join tsysOS On tsysOS.OScode = tblAssets.OScode
Where tblAssets.AssetID Not In (Select Top 1000000 tblFloppy.AssetID
From tblFloppy Where (tblFloppy.Model Like '%ssd%') Or
(tblFloppy.Model Like '%solid%state%')) And tblAssets.Lastseen <> '' And
tblAssets.Lastseen Is Not Null And tblAssetCustom.State = 1
Order By tblAssets.Domain,
tblAssets.AssetName
‎05-23-2018 01:36 PM
Select Top (1000000) tsysOS.Image As icon,
tblAssets.AssetID,
tblAssets.AssetName,
tblAssets.Domain,
tblAssets.Username,
tblAssets.Userdomain,
tblAssets.IPAddress,
tblAssets.Firstseen,
tblAssets.Lastseen,
tblFloppy.Model,
tblAssetCustom.State
From tblFloppy
Inner Join tblAssets On tblFloppy.AssetID = tblAssets.AssetID
Inner Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
Inner Join tsysOS On tblAssets.OScode = tsysOS.OScode
Where (dbo.tblFloppy.Model Like N'%SSD%') Or
(dbo.tblFloppy.Model Like N'%solid%state%' And Not (dbo.tblAssets.Lastseen Is
Null) And dbo.tblAssetCustom.State = 1)
Select Top (1000000) tsysOS.Image As icon,
tblAssets.AssetID,
tblAssets.AssetName,
tblAssets.Domain,
tblAssets.Username,
tblAssets.Userdomain,
tblAssets.IPAddress,
tblAssets.Firstseen,
tblAssets.Lastseen,
tblFloppy.Model,
tblAssetCustom.State
From tblFloppy
Inner Join tblAssets On tblFloppy.AssetID = tblAssets.AssetID
Inner Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
Inner Join tsysOS On tblAssets.OScode = tsysOS.OScode
Where Not (dbo.tblFloppy.Model Like N'%SSD%') And Not (dbo.tblFloppy.Model Like
N'%solid%state%') And Not (dbo.tblFloppy.Model Like N'%OCZ%') And
Not (dbo.tblFloppy.Model Like N'%solid%state%') And
Not (dbo.tblFloppy.Model Like N'%SV300%') And Not (dbo.tblFloppy.Model Like
N'%Sandisk X%') And Not (dbo.tblFloppy.Model Like N'%Samsung SSD%') And
Not (dbo.tblFloppy.Model Like N'%Intel SSD%') And
Not (dbo.tblFloppy.Model Like N'%solid%state%') And
Not (dbo.tblFloppy.Model Like N'%SAMSUNG MZ%') And
Not (dbo.tblFloppy.Model Like N'%Virtual%') And Not (dbo.tblFloppy.Model Like
N'%LITEON LCH%') And Not (dbo.tblFloppy.Model Like N'%Dell%') And
Not (dbo.tblFloppy.Model Like N'%RAID%') And Not (dbo.tblFloppy.Model Like
N'%SanDisk SD%') And Not (dbo.tblFloppy.Model Like N'%SAMSUNG KU%') And
Not (dbo.tblFloppy.Model Like N'%LITEONIT LCS%') And
Not (dbo.tblFloppy.Model Like N'%MTFDDAK128MAY%') And
Not (dbo.tblFloppy.Model Like N'%Intel MegaSR%') And
Not (dbo.tblFloppy.Model Like N'%Generic%') And Not (dbo.tblFloppy.Model Like
N'%Micron 1100%') And Not (dbo.tblFloppy.Model Like N'%KINGSTON SKC%') And
Not (dbo.tblFloppy.Model Like N'%THNSN%') And Not (dbo.tblFloppy.Model Like
N'%External%') And Not (dbo.tblFloppy.Model Like N'%Expansion%') And
Not (dbo.tblFloppy.Model Like N'%USB%') And Not (dbo.tblFloppy.Model
Like N'%LSI%') And Not (dbo.tblFloppy.Model Like N'%Microsoft Storage Space%')
And Not (dbo.tblFloppy.Model Like N'%Kingston S10032%') And
Not (dbo.tblFloppy.Model Like N'%asmedia ASMT%') And
Not (dbo.tblAssets.Lastseen Is Null) And dbo.tblAssetCustom.State = 1
‎05-14-2019 09:15 PM
spgs wrote:
Could not get this to work, so created own one that does work
Select Top (1000000) tsysOS.Image As icon,
tblAssets.AssetID,
tblAssets.AssetName,
tblAssets.Domain,
tblAssets.Username,
tblAssets.Userdomain,
tblAssets.IPAddress,
tblAssets.Firstseen,
tblAssets.Lastseen,
tblFloppy.Model,
tblAssetCustom.State
From tblFloppy
Inner Join tblAssets On tblFloppy.AssetID = tblAssets.AssetID
Inner Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
Inner Join tsysOS On tblAssets.OScode = tsysOS.OScode
Where (dbo.tblFloppy.Model Like N'%SSD%') Or
(dbo.tblFloppy.Model Like N'%solid%state%' And Not (dbo.tblAssets.Lastseen Is
Null) And dbo.tblAssetCustom.State = 1)
OR PCs WITHOUT SSD
Select Top (1000000) tsysOS.Image As icon,
tblAssets.AssetID,
tblAssets.AssetName,
tblAssets.Domain,
tblAssets.Username,
tblAssets.Userdomain,
tblAssets.IPAddress,
tblAssets.Firstseen,
tblAssets.Lastseen,
tblFloppy.Model,
tblAssetCustom.State
From tblFloppy
Inner Join tblAssets On tblFloppy.AssetID = tblAssets.AssetID
Inner Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
Inner Join tsysOS On tblAssets.OScode = tsysOS.OScode
Where Not (dbo.tblFloppy.Model Like N'%SSD%') And Not (dbo.tblFloppy.Model Like
N'%solid%state%') And Not (dbo.tblFloppy.Model Like N'%OCZ%') And
Not (dbo.tblFloppy.Model Like N'%solid%state%') And
Not (dbo.tblFloppy.Model Like N'%SV300%') And Not (dbo.tblFloppy.Model Like
N'%Sandisk X%') And Not (dbo.tblFloppy.Model Like N'%Samsung SSD%') And
Not (dbo.tblFloppy.Model Like N'%Intel SSD%') And
Not (dbo.tblFloppy.Model Like N'%solid%state%') And
Not (dbo.tblFloppy.Model Like N'%SAMSUNG MZ%') And
Not (dbo.tblFloppy.Model Like N'%Virtual%') And Not (dbo.tblFloppy.Model Like
N'%LITEON LCH%') And Not (dbo.tblFloppy.Model Like N'%Dell%') And
Not (dbo.tblFloppy.Model Like N'%RAID%') And Not (dbo.tblFloppy.Model Like
N'%SanDisk SD%') And Not (dbo.tblFloppy.Model Like N'%SAMSUNG KU%') And
Not (dbo.tblFloppy.Model Like N'%LITEONIT LCS%') And
Not (dbo.tblFloppy.Model Like N'%MTFDDAK128MAY%') And
Not (dbo.tblFloppy.Model Like N'%Intel MegaSR%') And
Not (dbo.tblFloppy.Model Like N'%Generic%') And Not (dbo.tblFloppy.Model Like
N'%Micron 1100%') And Not (dbo.tblFloppy.Model Like N'%KINGSTON SKC%') And
Not (dbo.tblFloppy.Model Like N'%THNSN%') And Not (dbo.tblFloppy.Model Like
N'%External%') And Not (dbo.tblFloppy.Model Like N'%Expansion%') And
Not (dbo.tblFloppy.Model Like N'%USB%') And Not (dbo.tblFloppy.Model
Like N'%LSI%') And Not (dbo.tblFloppy.Model Like N'%Microsoft Storage Space%')
And Not (dbo.tblFloppy.Model Like N'%Kingston S10032%') And
Not (dbo.tblFloppy.Model Like N'%asmedia ASMT%') And
Not (dbo.tblAssets.Lastseen Is Null) And dbo.tblAssetCustom.State = 1
Experience Lansweeper with your own data. Sign up now for a 14-day free trial.
Try Now