Find out if a value in a list is in another list

Hi all. Does anyone know how to know if a value of a list is in another list?

Solved Solved
0 6 1,568
1 ACCEPTED SOLUTION

Oh if you want to see if the item is in the table or not, you can use the IN() expression.

So on the format rule "If this condition is true" you can use

NOT(IN([_THISROW].[IDColumn], OtherTable[RefColumn])) 

This assumes that you have a ref column between the two tables.

View solution in original post

6 REPLIES 6


@Gustavo_Eduardo wrote:

Hi all. Does anyone know how to know if a value of a list is in another list?


Reformulate your question, pls:
One value from list1 present in list2
Or
All values from list1 presents in list2

In any case you can find answer here
https://help.appsheet.com/en/articles/961274-list-expressions

How are you bonameblisto!, thanks for your answer. I've created an "Add Item" button to a list, which should only be active if it's not in the new list, so that I can't add it twice.

I have created a "Format Rules" and, where it says:

If this condition is true
Condition to check before formatting

I must place the condition that makes the icon appear if it is not in the other table.

What I want is for the button to appear if I haven't added the item to the table.

Oh if you want to see if the item is in the table or not, you can use the IN() expression.

So on the format rule "If this condition is true" you can use

NOT(IN([_THISROW].[IDColumn], OtherTable[RefColumn])) 

This assumes that you have a ref column between the two tables.

Aurelien
Google Developer Expert
Google Developer Expert

Hi  @Gustavo_Eduardo 

 

You may want to use this expression:

ISNOTBLANK(INTERSECT(LIST1, LIST2))

 

For reference:

https://help.appsheet.com/en/articles/3483429-intersect

 

Hello Aurelien, thank you for your answer. I've created an "Add Item" button to a list, which should only be active if it's not in the new list, so that I can't add it twice.

I have created a "Format Rules" and, where it says:

If this condition is true
Condition to check before formatting

I must place the condition that makes the icon appear if it is not in the other table.

OK, so that should be something like:

NOT(IN([_THISROW],yourList))

 

It all depends on your data structure actually, but basically this is it.

Top Labels in this Space