Forum Discussion
Compare Multiple Rows to Each Other and Lookup
- 1 year ago
Hi Dilbertfan,
The matrix solution is pretty easy to achieve.
You will need two non-related Dataset tables, two non-synched slicers and a measure like the one below.
_lookupMeasure = VAR ds1 = SELECTEDVALUE(Datasets[Name]) VAR ds2 = SELECTEDVALUE('Datasets 2'[Name]) VAR s1 = SELECTEDVALUE(Datasets[Sensitivity]) VAR s2 = SELECTEDVALUE('Datasets 2'[Sensitivity]) RETURN IF ( ds1 <> ds2, MAXX ( FILTER ( Lookup, Lookup[Dataset 1] = s1 && Lookup[Dataset 2] = s2 ), [Result] ) )Please check the Musings tab of your file modified by me.
Best Regards,
Alexander
- 1 year ago
The list solution can be achieved with the help of the same measure and specific settings in a matrix.
Best Regards,
Alexander
Thanks barritown - great of you to explain.
Makes sense, just initially hard to get your head around - I sort of knew this, but it is the act of selecting 4 records in the slicer, which is throwing me off. So in the context of the table or matrix it works, but if you tried to use SELECTEDVALUE in a card, then it would break as you dont have the filter context to bring it to a single value?
Thanks again
Rich
My pleasure. 🙂
Yup, in case you use it in a card, the solution will work only your slicers allows only one value to be selected.
Best Regards,
Alexander