Enumlist intercept

Good evening all,

I have a FilterTable which contains a column that is of type Enumlist.
I have a DataTable which contains a column that is of type Enumlist.

I want to create a slice based on having at-least 1 common selection in both Enumlists.

Both are of the same Type. EnumList with a base Type of Ref.

Im not understanding how I would accomplish something like this. especially with intercept. Does not seem to work the same as with a list.

Any help would be appreciated.

Thanks,

Solved Solved
0 11 1,204
1 ACCEPTED SOLUTION

Please try

INTERSECT(SPLIT(Selected Plant Line Settings[Currant Line #], โ€œ,โ€) , [Line #])>0

or

INTERSECT(SPLIT((Selected Plant Line Settings[Currant Line #]) , โ€œ,โ€) , [Line #])>0

View solution in original post

11 REPLIES 11

I believe you may wish to add following details

  1. Are the two Enumlist columns referencing the same table?

  2. Is the slice on the same data table where one of the two Enumlist columns is there?

  3. Are the Enumlist columns displaying labels of the referenced table rather than key

  4. Does the filter table have a single row or one row per user?

They are Both Referencing the Same Table.
The Slice will be on the DataTable
Thee Enumlist columns are displaying label of the referenced Table.
The Filter Table has a Security filter to only show uuid from that user. but has multiple rows per user so I can see filter history and overall effectiveness. The Value I need to use is the MAXRow Value of the filtertable.

Thank you.

One more detail is if the slice will populate with at least one common value between Enumlists. If there are more , the slice will populate with those values as well?

The Slice will be Based on filter,

IffFilter has 3 items selected, the slice would only show the DataTable Items which has at-least these 3 items, but could also have other items, as long as the filter items are in the Data-table Row.

Thank you. I believe in general it will be something like below based on the description and understanding so far

  1. Create a VC called MAXROWBYUSER with expression MAXROW(โ€œFilter Tableโ€, โ€œ_ROWNumberโ€) in the Data Table. Here the MAXROW is assumed to be by the latest row number, You may wish to substitute it by say date or suitable column in the filter table.

  2. Create another column called say MAXFILTER with expression [MAXROWBYUSER].[EnumLIstFilterTableColumn]

I believe the slice filter expression can be

INTERSECT([MAXFILTER], [EnumlistDataTableColumn])>0

Expressions will change based on the exact configuration, column names in the actual app.

Im a little confused because everything ive tried thus far give me this error

INTERSECT does not accept a list of list.

This is formula.

INTERSECT(Selected Plant Line Settings[Currant Line #], [Line #])

Also tried

INTERSECT(any(Selected Plant Line Settings[Currant Line #]), [Line #])

Gives this Error
INTERSECT takes two arguments of type List.

Please try

INTERSECT(SPLIT(Selected Plant Line Settings[Currant Line #], โ€œ,โ€) , [Line #])>0

or

INTERSECT(SPLIT((Selected Plant Line Settings[Currant Line #]) , โ€œ,โ€) , [Line #])>0

This seems to have done it. Very wierd way of doing things.

Thanks!

Hi @Jonathan_S,

Thank you for the update and good to know it works per your needs.

I believe the error you got is logical. The SELECT() statement implemented on an enumlist column creates a list of lists since each enumlist columns itself is a list.

So I trust one needs a SPLIT() function to naturalize that list of lists into a list of individual elements.

Steve
Platinum 5
Platinum 5

Possibly?

ISNOTBLANK(
  FILTER(
    "FilterTable",
    ISBLANK(
      [Currant Line #]
      - [_THISROW].[Currant Line #]
    )
  )
)

Thanks

Top Labels in this Space