PRUEBA AHORA

Mozilla Firefox Version Audit

Software

Discover which Firefox installations are out of date with the version audit. The audit checks all Firefox versions in your IT environment and shows devices that are not running the highest version detected. To ensure the best accuracy, install the latest version on a single device and rescan it.

Note: The Lansweeper Site version of this audit does utilize the comparison functionality

Run The Mozilla Firefox Version Audit Report Now!

Firefox version audit example

Mozilla Firefox Version Audit On-Prem Query

Select Top 1000000 tblAssets.AssetID,
Coalesce(tsysOS.Image, tsysAssetTypes.AssetTypeIcon10) As icon,
 tblAssets.AssetName,
tblSoftwareUni.softwareName,
 tblSoftwareUni.SoftwarePublisher As Publisher,
  case when
 LEN(tblSoftware.softwareVersion) - Len(Replace(tblSoftware.softwareVersion, '.', '')) = 1 then tblSoftware.softwareVersion + '.0' 
 when LEN(tblSoftware.softwareVersion) - Len(Replace(tblSoftware.softwareVersion, '.', '')) = 3 then SUBSTRING(tblSoftware.softwareVersion, 1, LEN(tblSoftware.softwareVersion) - 2)
else tblSoftware.softwareVersion
end As Version,
 b.LatestVersion,
 tblSoftware.Lastchanged,
 tblassets.Lastseen
From tblAssets
 Inner Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
 Inner Join tblState On tblState.State = tblAssetCustom.State
 Inner Join tblSoftware On tblAssets.AssetID = tblSoftware.AssetID
 Inner Join tblSoftwareUni On tblSoftwareUni.SoftID = tblSoftware.softID
  Inner Join tsysAssetTypes On tsysAssetTypes.AssetType = tblAssets.Assettype
Left Outer Join tsysOS On tsysOS.OScode = tblAssets.OScode
 Inner Join (Select __.SoftID,
   __.Major,
   __.Minor,
   __.Build,
   __.Revision,
   LatestVersion = __.softwareVersion
  From (Select *,
     r = Row_Number() Over (Partition By _.SoftID Order By _.Major Desc,
     _.Minor Desc, _.Build Desc, _.Revision Desc)
    From (Select Distinct tblSoftware.SoftID,
       Major = Convert(int,ParseName( case when
 LEN(tblSoftware.softwareVersion) - Len(Replace(tblSoftware.softwareVersion, '.', '')) = 1 then tblSoftware.softwareVersion + '.0' 
 when LEN(tblSoftware.softwareVersion) - Len(Replace(tblSoftware.softwareVersion, '.', '')) = 3 then SUBSTRING(tblSoftware.softwareVersion, 1, LEN(tblSoftware.softwareVersion) - 2)
else tblSoftware.softwareVersion
end, 4)),
       Minor = Convert(int,ParseName( case when
 LEN(tblSoftware.softwareVersion) - Len(Replace(tblSoftware.softwareVersion, '.', '')) = 1 then tblSoftware.softwareVersion + '.0' 
 when LEN(tblSoftware.softwareVersion) - Len(Replace(tblSoftware.softwareVersion, '.', '')) = 3 then SUBSTRING(tblSoftware.softwareVersion, 1, LEN(tblSoftware.softwareVersion) - 2)
else tblSoftware.softwareVersion
end, 3)),
       Build = Convert(int,ParseName( case when
 LEN(tblSoftware.softwareVersion) - Len(Replace(tblSoftware.softwareVersion, '.', '')) = 1 then tblSoftware.softwareVersion + '.0' 
 when LEN(tblSoftware.softwareVersion) - Len(Replace(tblSoftware.softwareVersion, '.', '')) = 3 then SUBSTRING(tblSoftware.softwareVersion, 1, LEN(tblSoftware.softwareVersion) - 2)
else tblSoftware.softwareVersion
end, 2)),
       Revision = Convert(int,ParseName( case when
 LEN(tblSoftware.softwareVersion) - Len(Replace(tblSoftware.softwareVersion, '.', '')) = 1 then tblSoftware.softwareVersion + '.0' 
 when LEN(tblSoftware.softwareVersion) - Len(Replace(tblSoftware.softwareVersion, '.', '')) = 3 then SUBSTRING(tblSoftware.softwareVersion, 1, LEN(tblSoftware.softwareVersion) - 2)
else tblSoftware.softwareVersion
end, 1)),
        case when
 LEN(tblSoftware.softwareVersion) - Len(Replace(tblSoftware.softwareVersion, '.', '')) = 1 then tblSoftware.softwareVersion + '.0' 
 when LEN(tblSoftware.softwareVersion) - Len(Replace(tblSoftware.softwareVersion, '.', '')) = 3 then SUBSTRING(tblSoftware.softwareVersion, 1, LEN(tblSoftware.softwareVersion) - 2)
else tblSoftware.softwareVersion
end as softwareVersion
      From tblSoftware
       Inner Join tblSoftwareUni On tblSoftware.SoftID =
         tblSoftwareUni.SoftID
      Where tblSoftwareUni.softwareName  Like ('%firefox%')) _) __
  Where __.r = 1) b On tblSoftware.SoftID = b.SoftID And
    case when
 LEN(tblSoftware.softwareVersion) - Len(Replace(tblSoftware.softwareVersion, '.', '')) = 1 then tblSoftware.softwareVersion + '.0' 
 when LEN(tblSoftware.softwareVersion) - Len(Replace(tblSoftware.softwareVersion, '.', '')) = 3 then SUBSTRING(tblSoftware.softwareVersion, 1, LEN(tblSoftware.softwareVersion) - 2)
else tblSoftware.softwareVersion
end <> b.LatestVersion
Where tblSoftwareUni.softwareName like ('%firefox%')
Union
Select Top 1000000 tblAssets.AssetID,
Coalesce(tsysOS.Image, tsysAssetTypes.AssetTypeIcon10) As icon,
 tblAssets.AssetName,
tblSoftwareUni.softwareName,
 tblSoftwareUni.SoftwarePublisher As Publisher,
tblMacApplications.Version,
 b.LatestVersion,
 tblMacApplications.Lastchanged,
 tblassets.Lastseen
From tblAssets
 Inner Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
 Inner Join tblState On tblState.State = tblAssetCustom.State
 Inner Join tblMacApplications On tblAssets.AssetID = tblMacApplications.AssetID
 Inner Join tblSoftwareUni On tblSoftwareUni.SoftID = tblMacApplications.softid
  Inner Join tsysAssetTypes On tsysAssetTypes.AssetType = tblAssets.Assettype
Left Outer Join tsysOS On tsysOS.OScode = tblAssets.OScode
 Inner Join (Select __.SoftID,
   __.Major,
   __.Minor,
   __.Build,
   __.Revision,
   LatestVersion = __.Version
  From (Select *,
     r = Row_Number() Over (Partition By _.SoftID Order By _.Major Desc,
     _.Minor Desc, _.Build Desc, _.Revision Desc)
    From (Select Distinct tblMacApplications.SoftID,
       Major = Convert(int,ParseName(Case
When tblMacApplications.Version Like '%R%' Then
Left(tblMacApplications.Version, CharIndex('R',
tblMacApplications.Version) - 1)
Else tblMacApplications.Version
End, 4)),
       Minor = Convert(int,ParseName(Case
When tblMacApplications.Version Like '%R%' Then
Left(tblMacApplications.Version, CharIndex('R',
tblMacApplications.Version) - 1)
Else tblMacApplications.Version
End, 3)),
       Build = Convert(int,ParseName(Case
When tblMacApplications.Version Like '%R%' Then
Left(tblMacApplications.Version, CharIndex('R',
tblMacApplications.Version) - 1)
Else tblMacApplications.Version
End, 2)),
       Revision = Convert(int,ParseName(Case
When tblMacApplications.Version Like '%R%' Then
Left(tblMacApplications.Version, CharIndex('R',
tblMacApplications.Version) - 1)
Else tblMacApplications.Version
End, 1)),
       tblMacApplications.Version
      From tblMacApplications
       Inner Join tblSoftwareUni On tblMacApplications.SoftID =
         tblSoftwareUni.SoftID
      Where tblSoftwareUni.softwareName Like ('%firefox%')) _) __
  Where __.r = 1) b On tblMacApplications.SoftID = b.SoftID And
   tblMacApplications.Version <> b.LatestVersion
Where tblSoftwareUni.softwareName like ('%firefox%') And tblState.Statename = 'Active'

Union

Select Top 1000000 tblAssets.AssetID,
Coalesce(tsysOS.Image, tsysAssetTypes.AssetTypeIcon10) As icon,
 tblAssets.AssetName,
 tblSoftwareUni.softwareName As Software,
 tblSoftwareUni.SoftwarePublisher As Publisher,
 Case
When 
tblLinuxSystem.OSRelease Like '%Ubuntu%' And
tblSoftwareUni.softwareName Not Like '%esr%' And
tblLinuxSoftware.Version Like '%+%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 1)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 1)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 1) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 1)
end
When tblLinuxSystem.OSRelease Like '%Ubuntu%' And
tblSoftwareUni.softwareName Like '%esr%' And
tblLinuxSoftware.Version Like '%+%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 4)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 4)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 4) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 4)
end
When tblLinuxSystem.OSRelease Like '%manjaro%' And
tblSoftwareUni.softwareName Not Like '%esr%' And
tblLinuxSoftware.Version Like '%-%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)
end
When tblLinuxSystem.OSRelease Like '%manjaro%' And
tblSoftwareUni.softwareName Like '%esr%' And
tblLinuxSoftware.Version Like '%-%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)
end
When tblLinuxSystem.OSRelease Like '%manjaro%' And
tblSoftwareUni.softwareName Like '%esr%' And
tblLinuxSoftware.Version Like '%esr-%' And
tblLinuxSoftware.Version Like '%.%.%[^0-9]%' Then
case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)
end
When tblLinuxSystem.OSRelease Like '%debian%' And
tblSoftwareUni.softwareName Not Like '%esr%' And
tblLinuxSoftware.Version Like '%-%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)
end
When tblLinuxSystem.OSRelease Like '%debian%' And
tblSoftwareUni.softwareName Like '%esr%' And
tblLinuxSoftware.Version Like '%-%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)
end
Else tblLinuxSoftware.Version
END As Version,
 b.LatestVersion,
  tblLinuxSoftware.Lastchanged,
  tblassets.Lastseen
From tblAssets
 Inner Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
 Inner Join tblState On tblState.State = tblAssetCustom.State
 Inner Join tblLinuxSoftware On tblAssets.AssetID = tblLinuxSoftware.AssetID
 Inner Join tblSoftwareUni On tblSoftwareUni.SoftID = tblLinuxSoftware.SoftwareUniID
 Inner Join tblLinuxSystem On tblAssets.AssetID = tblLinuxSystem.AssetID
  Inner Join tsysAssetTypes On tsysAssetTypes.AssetType = tblAssets.Assettype
Left Outer Join tsysOS On tsysOS.OScode = tblAssets.OScode
 Inner Join (Select __.SoftwareUniID,
   __.Major,
   __.Minor,
   __.Build,
   __.Revision,
   LatestVersion = __.Version
  From (Select *,
     r = Row_Number() Over (Partition By _.SoftwareUniID Order By _.Major Desc,
     _.Minor Desc, _.Build Desc, _.Revision Desc)
    From (Select Distinct tblLinuxSoftware.SoftwareUniID,
       Major = Convert(int,ParseName(
	   Case
When 
tblLinuxSystem.OSRelease Like '%Ubuntu%' And
tblSoftwareUni.softwareName Not Like '%esr%' And
tblLinuxSoftware.Version Like '%+%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 1)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 1)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 1) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 1)
end
When tblLinuxSystem.OSRelease Like '%Ubuntu%' And
tblSoftwareUni.softwareName Like '%esr%' And
tblLinuxSoftware.Version Like '%+%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 4)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 4)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 4) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 4)
end
When tblLinuxSystem.OSRelease Like '%manjaro%' And
tblSoftwareUni.softwareName Not Like '%esr%' And
tblLinuxSoftware.Version Like '%-%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)
end
When tblLinuxSystem.OSRelease Like '%manjaro%' And
tblSoftwareUni.softwareName Like '%esr%' And
tblLinuxSoftware.Version Like '%-%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)
end
When tblLinuxSystem.OSRelease Like '%manjaro%' And
tblSoftwareUni.softwareName Like '%esr%' And
tblLinuxSoftware.Version Like '%esr-%' And
tblLinuxSoftware.Version Like '%.%.%[^0-9]%' Then
case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)
end
When tblLinuxSystem.OSRelease Like '%debian%' And
tblSoftwareUni.softwareName Not Like '%esr%' And
tblLinuxSoftware.Version Like '%-%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)
end
When tblLinuxSystem.OSRelease Like '%debian%' And
tblSoftwareUni.softwareName Like '%esr%' And
tblLinuxSoftware.Version Like '%-%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)
end
Else tblLinuxSoftware.Version
END, 4)),
       Minor = Convert(int,ParseName(Case
When 
tblLinuxSystem.OSRelease Like '%Ubuntu%' And
tblSoftwareUni.softwareName Not Like '%esr%' And
tblLinuxSoftware.Version Like '%+%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 1)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 1)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 1) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 1)
end
When tblLinuxSystem.OSRelease Like '%Ubuntu%' And
tblSoftwareUni.softwareName Like '%esr%' And
tblLinuxSoftware.Version Like '%+%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 4)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 4)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 4) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 4)
end
When tblLinuxSystem.OSRelease Like '%manjaro%' And
tblSoftwareUni.softwareName Not Like '%esr%' And
tblLinuxSoftware.Version Like '%-%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)
end
When tblLinuxSystem.OSRelease Like '%manjaro%' And
tblSoftwareUni.softwareName Like '%esr%' And
tblLinuxSoftware.Version Like '%-%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)
end
When tblLinuxSystem.OSRelease Like '%manjaro%' And
tblSoftwareUni.softwareName Like '%esr%' And
tblLinuxSoftware.Version Like '%esr-%' And
tblLinuxSoftware.Version Like '%.%.%[^0-9]%' Then
case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)
end
When tblLinuxSystem.OSRelease Like '%debian%' And
tblSoftwareUni.softwareName Not Like '%esr%' And
tblLinuxSoftware.Version Like '%-%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)
end
When tblLinuxSystem.OSRelease Like '%debian%' And
tblSoftwareUni.softwareName Like '%esr%' And
tblLinuxSoftware.Version Like '%-%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)
end
Else tblLinuxSoftware.Version
END, 3)),
       Build = Convert(int,ParseName(Case
When 
tblLinuxSystem.OSRelease Like '%Ubuntu%' And
tblSoftwareUni.softwareName Not Like '%esr%' And
tblLinuxSoftware.Version Like '%+%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 1)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 1)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 1) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 1)
end
When tblLinuxSystem.OSRelease Like '%Ubuntu%' And
tblSoftwareUni.softwareName Like '%esr%' And
tblLinuxSoftware.Version Like '%+%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 4)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 4)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 4) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 4)
end
When tblLinuxSystem.OSRelease Like '%manjaro%' And
tblSoftwareUni.softwareName Not Like '%esr%' And
tblLinuxSoftware.Version Like '%-%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)
end
When tblLinuxSystem.OSRelease Like '%manjaro%' And
tblSoftwareUni.softwareName Like '%esr%' And
tblLinuxSoftware.Version Like '%-%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)
end
When tblLinuxSystem.OSRelease Like '%manjaro%' And
tblSoftwareUni.softwareName Like '%esr%' And
tblLinuxSoftware.Version Like '%esr-%' And
tblLinuxSoftware.Version Like '%.%.%[^0-9]%' Then
case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)
end
When tblLinuxSystem.OSRelease Like '%debian%' And
tblSoftwareUni.softwareName Not Like '%esr%' And
tblLinuxSoftware.Version Like '%-%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)
end
When tblLinuxSystem.OSRelease Like '%debian%' And
tblSoftwareUni.softwareName Like '%esr%' And
tblLinuxSoftware.Version Like '%-%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)
end
Else tblLinuxSoftware.Version
END, 2)),
       Revision = Convert(int,ParseName(Case
When 
tblLinuxSystem.OSRelease Like '%Ubuntu%' And
tblSoftwareUni.softwareName Not Like '%esr%' And
tblLinuxSoftware.Version Like '%+%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 1)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 1)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 1) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 1)
end
When tblLinuxSystem.OSRelease Like '%Ubuntu%' And
tblSoftwareUni.softwareName Like '%esr%' And
tblLinuxSoftware.Version Like '%+%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 4)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 4)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 4) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 4)
end
When tblLinuxSystem.OSRelease Like '%manjaro%' And
tblSoftwareUni.softwareName Not Like '%esr%' And
tblLinuxSoftware.Version Like '%-%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)
end
When tblLinuxSystem.OSRelease Like '%manjaro%' And
tblSoftwareUni.softwareName Like '%esr%' And
tblLinuxSoftware.Version Like '%-%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)
end
When tblLinuxSystem.OSRelease Like '%manjaro%' And
tblSoftwareUni.softwareName Like '%esr%' And
tblLinuxSoftware.Version Like '%esr-%' And
tblLinuxSoftware.Version Like '%.%.%[^0-9]%' Then
case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)
end
When tblLinuxSystem.OSRelease Like '%debian%' And
tblSoftwareUni.softwareName Not Like '%esr%' And
tblLinuxSoftware.Version Like '%-%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)
end
When tblLinuxSystem.OSRelease Like '%debian%' And
tblSoftwareUni.softwareName Like '%esr%' And
tblLinuxSoftware.Version Like '%-%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)
end
Else tblLinuxSoftware.Version
END, 1)),

Case
When 
tblLinuxSystem.OSRelease Like '%Ubuntu%' And
tblSoftwareUni.softwareName Not Like '%esr%' And
tblLinuxSoftware.Version Like '%+%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 1)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 1)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 1) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 1)
end
When tblLinuxSystem.OSRelease Like '%Ubuntu%' And
tblSoftwareUni.softwareName Like '%esr%' And
tblLinuxSoftware.Version Like '%+%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 4)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 4)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 4) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 4)
end
When tblLinuxSystem.OSRelease Like '%manjaro%' And
tblSoftwareUni.softwareName Not Like '%esr%' And
tblLinuxSoftware.Version Like '%-%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)
end
When tblLinuxSystem.OSRelease Like '%manjaro%' And
tblSoftwareUni.softwareName Like '%esr%' And
tblLinuxSoftware.Version Like '%-%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)
end
When tblLinuxSystem.OSRelease Like '%manjaro%' And
tblSoftwareUni.softwareName Like '%esr%' And
tblLinuxSoftware.Version Like '%esr-%' And
tblLinuxSoftware.Version Like '%.%.%[^0-9]%' Then
case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)
end
When tblLinuxSystem.OSRelease Like '%debian%' And
tblSoftwareUni.softwareName Not Like '%esr%' And
tblLinuxSoftware.Version Like '%-%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)
end
When tblLinuxSystem.OSRelease Like '%debian%' And
tblSoftwareUni.softwareName Like '%esr%' And
tblLinuxSoftware.Version Like '%-%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)
end
Else tblLinuxSoftware.Version
END as [Version]
      From tblLinuxSoftware
       Inner Join tblSoftwareUni On tblLinuxSoftware.SoftwareUniID =
         tblSoftwareUni.SoftID
		 Inner Join tblLinuxSystem On tblLinuxSoftware.AssetID = tblLinuxSystem.AssetID
      Where tblSoftwareUni.softwareName In ('firefox', 'MozillaFirefox',
'firefox-esr')) _) __
  Where __.r = 1) b On tblLinuxSoftware.SoftwareUniID = b.SoftwareUniID And

Case
When 
tblLinuxSystem.OSRelease Like '%Ubuntu%' And
tblSoftwareUni.softwareName Not Like '%esr%' And
tblLinuxSoftware.Version Like '%+%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 1)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 1)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 1) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 1)
end
When tblLinuxSystem.OSRelease Like '%Ubuntu%' And
tblSoftwareUni.softwareName Like '%esr%' And
tblLinuxSoftware.Version Like '%+%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 4)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 4)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 4) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('+',
tblLinuxSoftware.Version) - 4)
end
When tblLinuxSystem.OSRelease Like '%manjaro%' And
tblSoftwareUni.softwareName Not Like '%esr%' And
tblLinuxSoftware.Version Like '%-%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)
end
When tblLinuxSystem.OSRelease Like '%manjaro%' And
tblSoftwareUni.softwareName Like '%esr%' And
tblLinuxSoftware.Version Like '%-%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)
end
When tblLinuxSystem.OSRelease Like '%manjaro%' And
tblSoftwareUni.softwareName Like '%esr%' And
tblLinuxSoftware.Version Like '%esr-%' And
tblLinuxSoftware.Version Like '%.%.%[^0-9]%' Then
case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)
end
When tblLinuxSystem.OSRelease Like '%debian%' And
tblSoftwareUni.softwareName Not Like '%esr%' And
tblLinuxSoftware.Version Like '%-%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 1)
end
When tblLinuxSystem.OSRelease Like '%debian%' And
tblSoftwareUni.softwareName Like '%esr%' And
tblLinuxSoftware.Version Like '%-%' And tblLinuxSoftware.Version Like
'%.%.%[^0-9]%' Then case when LEN(Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)) - Len(Replace((Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)), '.', '')) = 1 then Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4) + '.0' 
else Left(tblLinuxSoftware.Version, CharIndex('-',
tblLinuxSoftware.Version) - 4)
end
Else tblLinuxSoftware.Version
END <> b.LatestVersion
Where tblSoftwareUni.softwareName In ('firefox', 'MozillaFirefox',
'firefox-esr') And tblState.Statename = 'Active'

Show

Hide