What if in addition to Blank values for Total Sales, the customer has 0 values? Can you force 0s to blank using a Switch statement or nested IFs, so that you don’t have the first N number of customers with 0 Total Sales showing as the first N customers in your ranking?
DAX Used:
Customer Rank =
IF(ISBLANK([Total Sales]),BLANK(),
RANKX(
FILTER(ALL(Customer[Customer Name]), NOT(ISBLANK([Total Sales]))),
[Total Sales], , ASC) )
Customer Rank zeros =
IF([Total Sales] <= 0, BLANK(),
RANKX(
FILTER(ALL(Customer[Customer Name]), NOT(ISBLANK([Total Sales]))),
[Total Sales], , ASC) )
Custom Rank Blank and Zeros =
IF(ISBLANK([Total Sales]) || [Total Sales] <= 0,BLANK(),
RANKX(
FILTER(ALL(Customer[Customer Name]), NOT(ISBLANK([Total Sales]))),
[Total Sales], , ASC) )