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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
Anonymous
Not applicable

Count Customers with Number of Contact Points greater than Target Number of Contact Points

I have a list of Customer IDs, each has multiple contact points (Contact IDs). We have our customers grouped into various segments, each with a target for the number of contact points.

 

Customer Contacts in the segment ABC

Customer IDContact ID
1100
1103
1109
2123
2138
3150

 

That would be grouped into the following. I need the grouping to be affected by the selection of the segment slicer.

 

Customer IDContact Count
13
22
31

 

When a slicer is filtered to segment ABC, which has the target contact count of 2, I want to count the customers that have above that target and put it in a card. The result should be 1.

 

I've tried using different table structures and calculations. I'm quite flexible with how the table structures can be set up and I'm open to trying different calculations as long as they can be affected by a slicer.

 

Thanks!

 

1 ACCEPTED SOLUTION
Greg_Deckler
Community Champion
Community Champion

Should be something along the lines of:

 

Measure =
  VAR __Target = MAX('TargetTable'[Target])
  VAR __Table = 
    SUMMARIZE(
      'Table',
      [Customer ID],
      "Count",COUNTROWS('Table')
    )
RETURN
  COUNTROWS(FILTER(__Table,[Count]>=__Target))


Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

View solution in original post

1 REPLY 1
Greg_Deckler
Community Champion
Community Champion

Should be something along the lines of:

 

Measure =
  VAR __Target = MAX('TargetTable'[Target])
  VAR __Table = 
    SUMMARIZE(
      'Table',
      [Customer ID],
      "Count",COUNTROWS('Table')
    )
RETURN
  COUNTROWS(FILTER(__Table,[Count]>=__Target))


Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

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.

Top Solution Authors