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!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
Apologies if this is obvious, i have not been able to find a solution for this.
I have this measure
Solved! Go to Solution.
=
IF(
MAX( table1[PUBLISHED] ),
RANKX(
CALCULATETABLE( ALLSELECTED( table1[some column] ), table1[PUBLISHED] = TRUE ),
[measure]
)
)
| Thanks to the great efforts by MS engineers to simplify syntax of DAX! Most beginners are SUCCESSFULLY MISLED to think that they could easily master DAX; but it turns out that the intricacy of the most frequently used RANKX() is still way beyond their comprehension! |
DAX is simple, but NOT EASY! |
=
IF(
MAX( table1[PUBLISHED] ),
RANKX(
CALCULATETABLE( ALLSELECTED( table1[some column] ), table1[PUBLISHED] = TRUE ),
[measure]
)
)
| Thanks to the great efforts by MS engineers to simplify syntax of DAX! Most beginners are SUCCESSFULLY MISLED to think that they could easily master DAX; but it turns out that the intricacy of the most frequently used RANKX() is still way beyond their comprehension! |
DAX is simple, but NOT EASY! |
Brilliant, this works perfectly, thanks for your help.
Hey @Anonymous ,
you can use the FILTER function to filter something.
And if you use a measure you don't need a CALCULATE without any parameters. Try the following approach:
RANKX(FILTER(ALLSELECTED(Table1), Table1[myColumn] = "MyValue"),[measure], , DESC)
Hi Denis,
I have tried this but it is still giving ranks to rows that do not have that value:
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 38 | |
| 38 | |
| 36 | |
| 28 | |
| 28 |
| User | Count |
|---|---|
| 124 | |
| 88 | |
| 74 | |
| 66 | |
| 65 |