List expression works with expression assistant but not on app

We have enum list as one of the table columns. Example rows:
1=[A, B, C], 2=[B, C, D, E], 3=[A, F, C]

The requirement is to filter rows that contain all entries from a user provided input list.
ex: [B, C] : Answer = 1, 2
ex: [C, A] : Answer = 1, 3
ex: [F] : Answer = 3

To do this, I am using an expression that returns true if count of intersection of user list and row list is the same as count of the smaller list. I am using SPLIT to form a list from user provided comma separated text.

Expression:
IF(COUNT(SPLIT(User[List], " , ")) > COUNT([ColumnList]),
FALSE,
COUNT(INTERSECT(SPLIT(User[List], " , "), [ColumnList])) =
MIN({COUNT(SPLIT(User[List], " , ")), COUNT([ColumnList])})
)

With expression assistant, I see this expression working fine. But on the app, I don’t see any results when the user list has more than two entries. Any ideas?

Wow! Your expression is very complex! I propose there’s an easier way to get what you want:

ISBLANK([ColumnList] - User[List])

The result will be TRUE if User[List] contains all of the entries in [ColumnList]; otherwise, the result will be FALSE.

See also:

3 Likes

Thanks for the idea! What I wanted is this:

ISBLANK(User[List] - [ColumnList])

1 Like