
Select Top 1000000 tblAssets.AssetID, tblAssets.AssetName, tblAssets.Domain, tsysAssetTypes.AssetTypename As AssetType, tsysAssetTypes.AssetTypeIcon10 As icon, tblAssets.IPAddress, tblSoftwareUni.softwareName As Software, tblMacApplications.Version As Version, tsysIPLocations.IPLocation, tblAssetCustom.Manufacturer, tblAssetCustom.Model, tblMacOSInfo.SystemVersion As OS, tblAssets.Version as OSVersion, Case When tblErrors.ErrorText Is Not Null Or tblErrors.ErrorText != '' Then 'Scanning Error: ' + tsysasseterrortypes.ErrorMsg Else '' End As ScanningErrors, tblAssets.Lastseen, tblAssets.Lasttried, tblMacApplications.LastChanged From tblAssets Inner Join tblMacOSInfo On tblMacOSInfo.AssetID = tblAssets.AssetID Inner Join tblMacApplications On tblAssets.AssetID = tblMacApplications.AssetID Inner Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID Inner Join tsysAssetTypes On tsysAssetTypes.AssetType = tblAssets.Assettype Inner Join tsysIPLocations On tsysIPLocations.LocationID = tblAssets.LocationID Inner Join tblState On tblState.State = tblAssetCustom.State Inner Join tblSoftwareUni On tblSoftwareUni.SoftID = tblMacApplications.softID Left Join (Select Distinct Top 1000000 tblErrors.AssetID As ID, Max(tblErrors.Teller) As ErrorID From tblErrors Group By tblErrors.AssetID) As ScanningError On tblAssets.AssetID = ScanningError.ID Left Join tblErrors On ScanningError.ErrorID = tblErrors.Teller Left Join tsysasseterrortypes On tsysasseterrortypes.Errortype = tblErrors.ErrorType Where tblSoftwareUni.softwareName Like '%Safari%' And tblState.Statename = 'Active' and ((Len(tblMacApplications.Version) - Len(Replace(tblMacApplications.Version, '.', '')) = 1 And tblSoftwareUni.softwareName Like '%safari%' And Cast(ParseName(tblMacApplications.Version, 2) As bigint) < 15) or (Len(tblMacApplications.Version) - Len(Replace(tblMacApplications.Version, '.', '')) = 1 And tblSoftwareUni.softwareName Like '%safari%' And Cast(ParseName(tblMacApplications.Version, 2) As bigint) = 15 And Cast(ParseName(tblMacApplications.Version, 1) As bigint) < 6) or (Len(tblMacApplications.Version) - Len(Replace(tblMacApplications.Version, '.', '')) = 2 And tblSoftwareUni.softwareName Like '%safari%' And Cast(ParseName(tblMacApplications.Version, 3) As bigint) < 15) or (Len(tblMacApplications.Version) - Len(Replace(tblMacApplications.Version, '.', '')) = 2 And tblSoftwareUni.softwareName Like '%safari%' And Cast(ParseName(tblMacApplications.Version, 3) As bigint) = 15 And Cast(ParseName(tblMacApplications.Version, 2) As bigint) < 6) or (Len(tblMacApplications.Version) - Len(Replace(tblMacApplications.Version, '.', '')) = 2 And tblSoftwareUni.softwareName Like '%safari%' And Cast(ParseName(tblMacApplications.Version, 3) As bigint) = 15 And Cast(ParseName(tblMacApplications.Version, 2) As bigint) = 6 And Cast(ParseName(tblMacApplications.Version, 1) As bigint) < 1))
Explore the full platform, free for 14 days.
No credit card required.