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

Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM. Register now.

Reply
ameya4010
New Member

Applying filter to Measure and using Measure result to classify the output

Hi everyone.

I have following data:

 

A customer who bought units across different dates.

 

Customer

Posted On Date

Units

A

01/02/2022

1

A

01/02/2022

4

A

25/02/2022

1

A

25/02/2022

4

A

17/02/2023

1

A

17/02/2023

4

A

17/03/2023

1

A

17/03/2023

4

B

01/02/2022

4

B

01/02/2022

1

B

25/02/2022

4

B

25/02/2022

4

B

17/02/2023

1

B

17/02/2023

4

C

01/01/2023

6

C

01/01/2023

4

C

05/03/2023

10

D

01/01/2020

4

D

31/01/2020

4

D

03/03/2023

4

D

03/03/2023

4

 

 

 

 

 

When i select march from the date filter, i want to show the output only for customers who have bought in March

 

 

Currently, I am getting the following output:

ameya4010_0-1682499309166.png

 

 

I am using DISTINCTCOUNT and REMOVEFILTERS for the Total Count measure.

 

Ideally, when I select Monthofyear as 3, I would want to show only customers A,C and D and not B

 

2nd part of the question:

Based on Total count in the month of March, I would like to classify the customers.

 

A= High Buyer

C= Low Buyer

D= Medium Buyer

 

Would really appreciate your help to resolve this.

 

PS: How can i share the PBIX?

 

Thanks.

2 REPLIES 2
ameya4010
New Member

Thanks Amit.

 

If i use your suggestion, i get the following when i filter by 3.

 

ameya4010_0-1682522530793.png

The total count is only for March.

 

I want to show the customers who have bought in March, but their total count is includes all the unique dates historically.

 

Appreciate your help with this.

 

 

 

Ameya

amitchandak
Super User
Super User

@ameya4010 , filter is default behavior unless you created a measure to ignore that

 

measures

unit sold = sum(Table[Units])

 

Customers  = distinctcount(Table[Customer])

 

Should work with a date filter. You can create a date table and join with that if needed

 

You can refer to ABC analysis for the second ask

Power BI ABC Analysis using Window function, Dynamic Segmentation: https://youtu.be/A8mQND2xSR4

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.