Forum Academy Marketplace Showcase Pricing Features

Constraints are AND but what about OR

I want to do a DO SEARCH WHERE User Status A OR User Status B as an example…

How is this accomplished? Seem like they are all logical ANDs.

2 Likes

Use the “merged with” function to combine searches. Search for users of type A merged with search for users of type B.

1 Like

Here is what I have:

What I need:

Do search in Details table Where CreatedBy is created by AVATAR NAME = “MIKE” OR AVATAR NAME = “MARY” Where AVATAR NAME is in the User table. (Hard coded to those two user for example)

What I am doing:

Do Search: [Details Table Constraint: Created By = Do Search: [User Table Constraint: AVATAR NAME = MIKE] :first item] this works for MIKE only

So where do I place the Merge With?

Question - where is the search being made? Repeating group source? Group source? Field value?

Repeating group…

Ok, get rid of :first item and add “merged with” right after the search to be able to add the 2nd search.

A repeating group expects a list source, so as soon as you add :first item, you’ve turned it into single entry as its source, which the RG will not accept. Leave it as the merging of 2 searches and it will combine the entries that meet either search into a single list.

2 Likes

Yes that worked. You have to do the Merge With at the first level. I was trying to do it in the second level.

I have to use “first item” however at the user level to return a single user instead of list of users.

[Details Table Constraint: Created By = Do Search: [User Table Constraint: AVATAR NAME = MIKE] :first item]

[Details Table Constraint: Created By = Do Search: [User Table Constraint: AVATAR NAME = MARY] :first item]

This worked for both… I have two DO SEARCHs each nested with a corresponding DO SEARCH in the user table.

You got it! Excellent. Yes, good catch on the :first item in the inner User search.

1 Like

Many thanks!

This topic was automatically closed after 70 days. New replies are no longer allowed.