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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
KRISH80
Helper II
Helper II

Calculate TOP customer with multiple criteria

Dear All,

I need to RANK my Top customers my GP%. Below table has Customer Name, Contract Value, Profit and GP%.

But one condition that I need to apply is TOTAL Profit from the customer should be greater than 50K. From the below example, Accenture should not show up in my list as the TOTAL profit is less than 50K.

 

My current DAX to RANK is 

RANKX(ALL(FUNNEL[Customer Name]),[TOTAL-GP%], , DESC)
 
HOw should i modify this DAX to add that criteria of >50K ?
 

Rank.png

 

2 REPLIES 2
Pragati11
Super User
Super User

Hi @KRISH80 ,

 

Try modifying your DAX as follows:

RANKX(FILTER(FUNNEL, [TOTAL] > 50000), [TOTAL-GP%], , DESC)

 

If this helps and resolves the issue, appreciate a Kudos and mark it as a Solution! 🙂

 

Thanks,

Pragati

Best Regards,

Pragati Jain


MVP logo


LinkedIn | Twitter | Blog YouTube 

Did I answer your question? Mark my post as a solution! This will help others on the forum!

Appreciate your Kudos!!

Proud to be a Super User!!

Hi, This is not heping. Below is the actual DAX i am using. Where i have dynaic filed like Ranking Dimension and Ranking Select. In this code i need to add that condition of selecting ONLY accounts which have TOTAL-Gp of >50K

 

Top Accounts by Rank (GP%-OPEN) =
VAR
RankingDimension =VALUES(FUNNEL[Account Name])
VAR
RankingSelect = [Ranking Select]
RETURN
CALCULATE([TOTAL-OPEN-GP%],
Filter( RankingDimension,RANKX(ALL(FUNNEL[Account Name]),[TOTAL-OPEN-GP%], , DESC) <= RankingSelect))

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.

Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.