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
yamaro
New Member

Rankx excluding

Hello all,

 

I'm new using Power BI and I'm trying to create a Ranking based in a # by Country, but I want to exclude some of the countries from the ranking, is this possible? How can be done?

 

Thanks,

Yaitza

3 REPLIES 3
Vvelarde
Community Champion
Community Champion

@yamaro

 

Hi, use you can use a measure:

 

Rank-M =
RANKX ( ALLSELECTED ( Table1 ), CALCULATE ( SUM ( Table1[Sales] ) ),, DESC )

And apply a visual level filter to select the countries.

 

 

Filter.png

Regards

 

Victor

Lima - Peru




Lima - Peru

Hello @Vvelarde,

 

I tried that one, and didn't work. I'm trying to rank a measure, the measure was done for all the countries, not sure if that affect in the ranking.

 

Thanks

Hi @yamaro,

 

Would you please share some sample data and DAX of measure? Also please clarify the desired results regarding this sample data. 

 

Best Regards,
Qiuyun Yu 

Community Support Team _ Qiuyun Yu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

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.