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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
OmarSaleh
Helper I
Helper I

Ranking issue with RANKX

Hello

 

Can anyone please help resolving the following issue with RANKX. 

 

I'm trying to create a new measure to rank the names in below table based on their scores using RANKX 

 

 

 Rank = RANKX(All(Digital_Interactions),[Score])

 

 

Score is another measure that's calculated by multibliing and summing multible measures

 

 

 

 

 

 

Thanks!

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@OmarSaleh , what is the issue you are facing is not clear

You can try, assume you have name column 

Rank = RANKX(All(Digital_Interactions[Name]),[Score])

Rank = RANKX(AllSELECTED(Digital_Interactions[Name]),[Score])

 

For Rank Refer these links
https://radacad.com/how-to-use-rankx-in-dax-part-2-of-3-calculated-measures
https://radacad.com/how-to-use-rankx-in-dax-part-1-of-3-calculated-columns

View solution in original post

4 REPLIES 4
amitchandak
Super User
Super User

@OmarSaleh , what is the issue you are facing is not clear

You can try, assume you have name column 

Rank = RANKX(All(Digital_Interactions[Name]),[Score])

Rank = RANKX(AllSELECTED(Digital_Interactions[Name]),[Score])

 

For Rank Refer these links
https://radacad.com/how-to-use-rankx-in-dax-part-2-of-3-calculated-measures
https://radacad.com/how-to-use-rankx-in-dax-part-1-of-3-calculated-columns

Sorry @amitchandak just realised that I didn't mention the Name column after the table. It's working now thank you! 

Thanks @amitchandak for your reply. The issue is that I'm getting the same rank for all names even though I used ALL function as you advised. I don't have the score as a calculated column, it's a measure. 

@OmarSaleh , if you have created a measure rank on the name column and use another column in the visual. All Ranks will be done inside the second column 

refer

https://www.youtube.com/watch?v=DZb_6j6WuZ0

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

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