Forum Discussion
atitarev
7 years agoHelper I
Ranking issue
Hi Power BI experts, I am having an issue in getting the RANKX() working correctly for me. The ranking column is last, which is not working. It's based on the previous column "Sort". T...
- 7 years ago
Try the following formula:
Sorting Rank = IF ( HASONEVALUE ( DATA[Consolidation] ), RANKX ( ALL ( DATA[Consolidation], DATA[Level Leader] ), [Sort Measure], , ASC, Dense) )It shows this ranking
atitarev
7 years agoHelper I
[Sort Measure] is a measure
[Consoldiation] is the name of the column but [Business/Division] is the name used in the table.
I have obfuscated the data and saved a simplified version of the report:
I have shared the files on OneDrive:
Please let me know if you can't access them.
I found that without the [Leader] column it works OK, as in a 2nd page but I couldn't remove it using ALLEXCEPT.
Your assistance is appreciated.
themistoklis
7 years agoCommunity Champion
Try the following formula:
Sorting Rank = IF (
HASONEVALUE ( DATA[Consolidation] ),
RANKX ( ALL ( DATA[Consolidation], DATA[Level Leader] ), [Sort Measure], , ASC, Dense)
)It shows this ranking
- atitarev7 years agoHelper I
Thank you, themistoklis! That's exactly what I need.