cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
PBISean Regular Visitor
Regular Visitor

Rank Customer Names by Sales excluding Certain Customer Names

Hi,

 

I am a rookie in PBI. I want to rank customer names by sales. That sounds like an easy question. But I have to exclude certain customer names in ranking (particularly, i have to exclude all customrers with blank names in my dataset). 

 

I tried to filter the table and then do the ranking. It is not working for me. 

 

Thanks for help!

 

 

PBISean

4 REPLIES 4
Super User
Super User

Re: Rank Customer Names by Sales excluding Certain Customer Names

Hi @PBISean are you able to post a sample of your dataset?

 


 


Did I answer your question correctly? Mark my answer as a solution!


Proud to be a Datanaut!  

PBISean Regular Visitor
Regular Visitor

Re: Rank Customer Names by Sales excluding Certain Customer Names

Hi LivioLanzo,

 

Thanks for looking into this.

Here is a mock dataset for my purpose. I want to rank the Customer Name by Total Sales; however, I want to EXCLUDE the following two types of Customers in my ranking:

 

  1. Customers without Names, which are those BLANK cells in the Customer Name column
  2. Customers whose Sales Order Number are an even number

 

Customer Name

Sales

Sales Order Num

A

800

1

B

700

2

C

600

3

D

500

4

E

400

5

 

300

6

F

200

7

G

100

8

A

80

9

B

70

10

C

60

11

D

50

12

E

40

13

 

30

14

F

20

15

G

10

16

Community Support Team
Community Support Team

Re: Rank Customer Names by Sales excluding Certain Customer Names

@PBISean,

 

You may refer to the following post.

https://community.powerbi.com/t5/Desktop/RANKX-excluding-blanks/m-p/397656#M181491

Community Support Team _ Sam Zha
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
PBISean Regular Visitor
Regular Visitor

Re: Rank Customer Names by Sales excluding Certain Customer Names

Hi v-chuncz-msft,

 

Unfortunately, the post does not apply to my situation. 

 

The post is ranking the club but excluding club names which have blank YOY values.  

 

My situation is more like ranking the club but excluding the club names that are BLANK (let's call these clubs anonymous clubs). These anonymous clubs actually have YOY values. 

 

I tried to modified the formula in the post to my situation and it is not successful. 

 

Thanks,

 

PBISean