Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Reply
Nick221_
Frequent Visitor

RankX formula with tie's

I have the below formula that will rank my 'Risks" by the sum of Immediate high and Long term high. In some situations there are risks that have the same total number. In instances where there are ties, I would like the rank to order the risk that has more Immediate high responses.

 

Example.

 

Risk 1 Total number 54. Immediate high 24. Long Term High 30

Risk 2 Total number 52 Immediate high 43. Long Term High 9

Risk 3 Total number 52. Immediate high 48. Long Term High 4

 

Risk 1 should be 1 since it has higher total. Risk 3 should be come in at rank 2, because there is a higher number of Immediate High. Then Risk 2 at 3.

 

Here is my current formula:

Risk Order = RANKX(ALLSELECTED('Survey 2022'[Risks]),CALCULATE(SUM('Survey 2022'[Immediate High]) + SUM('Survey 2022'[Long Term High])))
1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

1 REPLY 1
amitchandak
Super User
Super User

@Nick221_ , You can choose tie breaker 

 

Rank Tie breaker
https://community.powerbi.com/t5/Community-Blog/Breaking-Ties-in-Rankings-with-RANKX-Using-Multiple-...
https://databear.com/how-to-use-the-dax-rankx-function-in-power-bi/

 

If you have small data to rank, you can consider Window

Learn Power BI: Window as Rank- why and Why not: https://youtu.be/Pu8y8bd5mb8

Helpful resources

Announcements
Europe Fabric Conference

Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.

AugPowerBI_Carousel

Power BI Monthly Update - August 2024

Check out the August 2024 Power BI update to learn about new features.

August Carousel

Fabric Community Update - August 2024

Find out what's new and trending in the Fabric Community.