Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more.
Get startedGrow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.
Hi all,
I am trying to work this out for ages. I found many different solutions online, but nothing worked. It's a simple one table one slicer solution. I need to filter the ID by the selected rules in the slicer. PBI default is OR condition, but I need to change it to AND.
data:
IDRule
1 | a |
2 | a |
2 | b |
3 | c |
3 | a |
3 | d |
4 | b |
4 | a |
5 | b |
6 | d |
6 | e |
7 | d |
7 | e |
7 | a |
7 | f |
7 | g |
8 | d |
8 | a |
9 | e |
10 | a |
10 | d |
Thanks 🙂
Solved! Go to Solution.
@WOLFIE , Try Measure
measure =
var _cnt = calculate(DistinctCount('Table'[Rule]) ,allselected('Table'))
return
countx(filter(summarize('Table', 'Table'[ID], "_1", DistinctCount('Table'[Rule])),[_1]=_cnt),[ID])
or
measure =
var _cnt = calculate(DistinctCount('Table'[Rule]) ,allselected('Table'))
return
calculate(countx(filter(summarize('Table', 'Table'[ID], "_1", DistinctCount('Table'[Rule])),[_1]=_cnt),[ID]), filter(allselected(Table), Table[ID] =max(Table[ID])))
@amitchandak Quick additional question 🙂 I need the table to keep all values when nothing is selected in the slicer. I tried this, but it doesn't work:
@amitchandak Quick additional question 🙂 I need the table to keep all values when nothing is selected in the slicer. I tried this, but it doesn't work:
SOLVED 🙂
@WOLFIE , Try Measure
measure =
var _cnt = calculate(DistinctCount('Table'[Rule]) ,allselected('Table'))
return
countx(filter(summarize('Table', 'Table'[ID], "_1", DistinctCount('Table'[Rule])),[_1]=_cnt),[ID])
or
measure =
var _cnt = calculate(DistinctCount('Table'[Rule]) ,allselected('Table'))
return
calculate(countx(filter(summarize('Table', 'Table'[ID], "_1", DistinctCount('Table'[Rule])),[_1]=_cnt),[ID]), filter(allselected(Table), Table[ID] =max(Table[ID])))
The second one works! 🙂 Thanks so much!!!
Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.
User | Count |
---|---|
70 | |
36 | |
21 | |
18 | |
15 |
User | Count |
---|---|
128 | |
29 | |
28 | |
24 | |
22 |