Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
Hi All,
Need some help.
I have these two measures.
Item Ranking by Total Cost (Selected Range) =
IF( ISBLANK( [Total Cost] ),
BLANK (),
RANKX (
ALLSELECTED( 'Item'),
[Total Cost],
,
DESC,
Skip
)
)
Top Item Total Cost by Rank =
VAR
RankingDimension = VALUES( 'Item'[Item Name] )
VAR
RankingSelect = 'Ranking Selections'[Ranking Select]
RETURN
IF( ISBLANK([Total Cost]),
BLANK(),
CALCULATE( [Total Cost],
FILTER( RankingDimension,
RANKX( ALL('Item'[Item Name]), [Total Cost], ,Desc, SKIp) <= RankingSelect ) )
)
If these measures are used seperately, they are working correctly.
However when include my ranking measure with TOPN Measure. Below is what I get.
Can someone please help me fix the second Matrix?
1) Only selected TOP N are displayed
2) the Ranking is not working correctly, there are some ranks repeated twice however the Totalcost is not exactly same.
Third Question that is a tricky one. Is there a way I can create a Dynamic dropdown slicer from second matrix that shows me the list formatted as below?
Rank | Item Name | Total Cost
Thanks
@nadeemrajabali Seems like you need a Complex Selector: The Complex Selector - Microsoft Power BI Community
RANKX can be tricky to work with, particularly as a measure: To *Bleep* with RANKX! - Microsoft Power BI Community
There's a good chance you need a CALCULATE.
Check out the November 2025 Power BI update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
| User | Count |
|---|---|
| 10 | |
| 10 | |
| 8 | |
| 6 | |
| 6 |
| User | Count |
|---|---|
| 24 | |
| 19 | |
| 19 | |
| 15 | |
| 9 |