cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
liliachante Frequent Visitor
Frequent Visitor

Unique value for a rank

Hi,

I need a unique value for a ranking measure, but as my column has the same value ,the index doesn't increment. I Have two columns: 

Fruit and Fruit_Number. I create a measure totalFruit where I calculate a sum:

TotalFruit = SUM(Fruit[Fruit_Number])
Then I create a rank : 
Rank = RANKX(ALLSELECTED(Fruit);Fruit[TotalFruit];;DESC;Dense)
as Apricot and lemon have the same number 8, the value of the rank is 2 for each of them. I need 2 and 3 instead of having two 2; It's work with column but I don't want to use column . I need Measure.
 
Rank.PNG
Thank you in advance for your help.
 
Lilia

 

1 ACCEPTED SOLUTION

Accepted Solutions
Super User
Super User

Re: Unique value for a rank

Hi @liliachante 

 

Try the below article -  "Breaking Ties" section is what you need.
https://radacad.com/how-to-use-rankx-in-dax-part-2-of-3-calculated-measures

 

 

Best Regards,
Mariusz

If this post helps, then please consider Accepting it as the solution.

Please feel free to connect with me.
Mariusz Repczynski

 

View solution in original post

1 REPLY 1
Super User
Super User

Re: Unique value for a rank

Hi @liliachante 

 

Try the below article -  "Breaking Ties" section is what you need.
https://radacad.com/how-to-use-rankx-in-dax-part-2-of-3-calculated-measures

 

 

Best Regards,
Mariusz

If this post helps, then please consider Accepting it as the solution.

Please feel free to connect with me.
Mariusz Repczynski

 

View solution in original post

Helpful resources

Announcements
New Ranks and Rank Icons in 2020

New Ranks and Rank Icons in 2020

Read the announcement for more information!

New Kudos Given Badges Coming

New Kudos Given Badges Coming

We're rolling out new Kudos Given badges. Find out how many Kudos you've given.

November 2019 Community Highlights

November 2019 Community Highlights

Get an overview of the events and great community content from November.

Power Platform World Tour

Power Platform World Tour

Find out where you can attend!

Top Solution Authors
Top Kudoed Authors (Last 30 Days)