Slice filter expression works only for the first row of form table

Hello,

I wrote this expression for a slice filter: 

COUNT(INTERSECT(SPLIT(INDEX(Search Form[X],COUNT(Search Form[Unique Id]))," - "), SPLIT([X],"/")))>0

It should work like this: user inputs an EnumList (items are divided by " - "). In X column of "Tasks" table which is connected to this slice there are some cells with multiple items divided by "/". I want to get rows from "Tasks" table that have a common item in the X column with the input. 

I found out that this expression works in Test and when the input is the first row of the "Search Form" table. 

Do you have any idea what to change so it works every time? 

Thanks! 

Solved Solved
0 2 127
1 ACCEPTED SOLUTION

I believe you have a misconception about what slices are for. I think what you want to do instead is add a Virtual Column to your 'Search Form' table that generates a list of row references for the matching 'Task' records. It'd be something like:

FILTER( Tasks , ISNOTBLANK( INTERSECT( [X] , [_THISROW].[X] ) ) )

Column type would be 'List', and base type 'Ref'.

View solution in original post

2 REPLIES 2

I believe you have a misconception about what slices are for. I think what you want to do instead is add a Virtual Column to your 'Search Form' table that generates a list of row references for the matching 'Task' records. It'd be something like:

FILTER( Tasks , ISNOTBLANK( INTERSECT( [X] , [_THISROW].[X] ) ) )

Column type would be 'List', and base type 'Ref'.

Thank your so much! I was solving this for two days and I was slowly giving up. You saved my project ๐Ÿ™‚ 

Top Labels in this Space