Use AND operator between different filters in Experience Builder

344
1
05-15-2023 06:47 AM
Jelle_Stu_PR
Occasional Contributor II

Hi,

I have made one web map with one layer. This layer has several attributes.

I have added this map to an experience builder in ArcGIS Enterprise 10.9.1. I have set up different filters based on different attributes in the layer. The filters work individually, but not together.

Technically speaking, when I turn on one or more filter within one attribute (one filter widget), I want to filter using the OR operator. Between the filter widgets (attributes) I want the AND operator to be applied. Setting up the filtering within one filter widget works but not between filter widgets.  

In the screenshot below I would like the following filtering to be applied:

('Energie' OR 'Materialen') AND ('Circulaire Economie' OR 'Ruimtelijke kwaliteit').

Jelle_Stu_PR_2-1684157813170.png

I have control over the OR operator within one filter attribute. This is how I set up the OR operator within one attribute filter:

Jelle_Stu_PR_3-1684158260724.png

I cannot find a way to change the operator between the filter attributes. This always seems to be OR.

From my experience in ArcGIS Dashboards, the AND operator is always used when applying different filters. Here it seems to be OR. Is there a way to adjust this or work around it?

best regards,
Jelle Stuurman

0 Kudos
1 Reply
TonghuiMing
Esri Regular Contributor

@Jelle_Stu_PR 

Based on your screenshot, the OR is configured to apply between different filter items (your second screenshot is exactly the way to configure the logic operator between them). However, you mentioned that you want to do 'AND' - these two seem conflicted with each other.

 

In order to achieve your case, it would be better to put these into one single filter item in the SQL Expression Builder, with multiple clauses/clause sets; and then use 'AND' between them. Something like this:

TonghuiMing_0-1684202227495.png

TonghuiMing_1-1684202270874.png

 

Another way to achieve it - you can add two different Filter widgets, and use the same data source. In ExB, the AND operator is always used when applying different filter widgets (and other filters added to the same data source) as well:

TonghuiMing_2-1684203122565.png

 

0 Kudos