cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Alulux
Engaged Sweeper III
Hello, I was trying to create a Report to show me all Adobe Reader versions earlier than the current 11.0.03. The one I created only shows me everything from 11.0.2 down to 10.0.0, but not lower (9,8.7, etc).
Where´s the error in my report?

Select Top 1000000 tblAssets.AssetID,
tblAssets.AssetUnique,
tblAssets.Domain,
tblSoftwareUni.softwareName As software,
tblSoftware.softwareVersion As version,
tblSoftwareUni.SoftwarePublisher As publisher,
tsysOS.Image As icon
From tblSoftware
Inner Join tblAssets On tblSoftware.AssetID = tblAssets.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
Where tblSoftwareUni.softwareName Like '%Adobe Reader%' And
tblSoftware.softwareVersion < '11.0.03' And tblAssetCustom.State = 1
Order By tblAssets.AssetName,
software,
version
1 ACCEPTED SOLUTION
Hemoco
Lansweeper Alumni
Which software versions are "less than" 11.0.03 is determined based on alphabetical sorting of the tblSoftware.softwareVersion field. 9 is greater than 1 so 9.x software versions are "greater than" 11.x software versions.

You could try something like this instead to list software versions that are not like "11.0.03".
Select Top 1000000 tblAssets.AssetID,
tblAssets.AssetUnique,
tblAssets.Domain,
tblSoftwareUni.softwareName As software,
tblSoftware.softwareVersion As version,
tblSoftwareUni.SoftwarePublisher As publisher,
tsysOS.Image As icon
From tblSoftware
Inner Join tblAssets On tblSoftware.AssetID = tblAssets.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
Where tblSoftwareUni.softwareName Like '%Adobe Reader%' And
tblAssetCustom.State = 1 and tblSoftware.softwareVersion Not Like '11.0.03%'
Order By tblAssets.AssetName,
software,
version

View solution in original post

1 REPLY 1
Hemoco
Lansweeper Alumni
Which software versions are "less than" 11.0.03 is determined based on alphabetical sorting of the tblSoftware.softwareVersion field. 9 is greater than 1 so 9.x software versions are "greater than" 11.x software versions.

You could try something like this instead to list software versions that are not like "11.0.03".
Select Top 1000000 tblAssets.AssetID,
tblAssets.AssetUnique,
tblAssets.Domain,
tblSoftwareUni.softwareName As software,
tblSoftware.softwareVersion As version,
tblSoftwareUni.SoftwarePublisher As publisher,
tsysOS.Image As icon
From tblSoftware
Inner Join tblAssets On tblSoftware.AssetID = tblAssets.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
Where tblSoftwareUni.softwareName Like '%Adobe Reader%' And
tblAssetCustom.State = 1 and tblSoftware.softwareVersion Not Like '11.0.03%'
Order By tblAssets.AssetName,
software,
version