Cloud Provider Relevance for Computer Group

Hi, I need help putting together a relevance expression. The scenario is that we have an Analysis activated with the following relevance if (exists property "cloud provider") then ( name of cloud provider ) else (if (exists property "data source") then ( if (data source contains "ESX" or data source as lowercase contains "vmware") then "VMware" else if ( data source contains "Amazon" ) then "Amazon Web Services" else data source ) else "N/A")

(We might have taken it from the BigFix.me site?) Anyway… I need help creating a computer group that adds objects that have ‘VMware’ or ‘On Premises’ set as the value of the ‘Cloud Provider’ attribute (from the Analysis) and if the object exists in a specific custom site (which I can just add as a second option in the filter).

I have tried these

exists data source whose (it as lowercase = "vmware" or it as lowercase = "on premises")

exists property "Cloud Provider" whose (exists result of it and (value of result of it as lowercase = "vmware" or value of result of it as lowercase = "on premises"))

AND

exists property "Provider Name" whose (exists result of it and (value of result of it as lowercase = "vmware" or value of result of it as lowercase = "on premises"))

I just keep getting zero (0) results. Any help would be appreciated.

Note: If it helps, the name of the Analysis is called ‘Cloud Providers’, activated globally.

My suggestion - if in doubt, keep it simple and don’t mess with the initial structure if that is working - something along the lines of: (conditions you want) of (…initial code…)

(it as lowercase = "vmware" or it as lowercase = "on premises") of (if (exists property "cloud provider") then ( name of cloud provider ) else (if (exists property "data source") then ( if (data source contains "ESX" or data source as lowercase contains "vmware") then "VMware" else if ( data source contains "Amazon" ) then "Amazon Web Services" else data source ) else "N/A"))

1 Like

I came back to update the thread as I managed to get it working using the built-in ‘Unique ID’ attribute which has the same information set as a value but good to know I have options too. Thanks.