Filtered Search Using Or

I would like to do a search on a repeating group that currently shows a bunch of profiles. I understand that I need to do it on the repeating group itself, but I think it’s a bit tricky because I’d like to use “or” as well as “and”. Per the attached image, the filter parameters are specialty, language, and state.

For example, I’d like the repeating group to show the profiles that (1) have a specialty of A or B, AND (2) have a language of X or Y, AND (3) form of payment. If it’s too complicated for me to include or searches in both (1) and (2), I can live with using “or” only in (1). Any guidance would be super appreciated.

Thank you.

I don’t know how your data is structured or your search and filter settings, but let’s assume you have X, Y, and Z fields in your database. Each of them has more than one option, say 1, 2, 3.

So, let’s say you had dropdowns and that each one of them is already configured to display options 1, 2 and 3, each from a field (dropdown X, dropdown Y, dropdown Z).

The filter can be applied directly to the search (Do a search for…)

Add 3 constraints and for each one of them compare the respective fields using the “=” operator.

Field X = Dropdown list X value,
Field Y = Dropdown list Y value,
Field Z = Dropdown Z value.

Otherwise, if it’s a multidropdown, then the contraints won’t use the operator “=”, but “is in”, since here you can have a list of options.

In some cases, if you don’t need all filters filled, you can select an option (in the contraints area) “ignore empty constraints” and this will ignore any input/filter left empty.

So an observation, if you already have defined values ​​for the filters, I would advise using dropdowns (which forces the user to select the existing options), searchbox (which suggests the existing options when typing) or any other type of predefined input (checkbox) instead of free inputs.

Anyway, I don’t know if that was really the question, but I hope I helped in some way.

:slight_smile:

1 Like

Thanks for your response! This is basically what I’m trying to do, but I’m still having some trouble. Like you said, I already have three drop downs and each is already to configured to display the relevant options.

When I try to add the constraint for Practice Specialties in the repeating group, I’m limited to contains, doesn’t contain, is empty, and isn’t empty operators (see the first image). Practice Specialties is a multidropdrown down with an option set (see the second image), so I don’t see the 'is in" operator you referenced.

Any idea what’s going on?


You need to go down the path of using an advanced filter that does a count of the intersect between two lists. There are a good number of threads in the forum where this concept has been discussed.

1 Like

Thanks I figured this out.

sometimes what i have to do is merge 2 or more different searches of the same data type, that have slightly different conditions