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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Jmccoy
Helper II
Helper II

Calculating Customer Status

I have a table with customers, job name, and tot sell. The customer can show up multiple times depending on how many projects that have done with our company. I am looking to make a measure to show if the customer is existing or new. IF the customer shows up once in the column, they would be new. Otherwise the would be existing. 

1 ACCEPTED SOLUTION
v-xuding-msft
Community Support
Community Support

Hi @Jmccoy ,

I created a simple sample that you could try.

Measure = 
var count_customers = CALCULATE(COUNTROWS('Table'),ALLSELECTED('Table'[Total sales]))
return
IF(count_customers = 1, "New","Existing")

3.PNG 

Best Regards,

Xue Ding

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Best Regards,
Xue Ding
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

1 REPLY 1
v-xuding-msft
Community Support
Community Support

Hi @Jmccoy ,

I created a simple sample that you could try.

Measure = 
var count_customers = CALCULATE(COUNTROWS('Table'),ALLSELECTED('Table'[Total sales]))
return
IF(count_customers = 1, "New","Existing")

3.PNG 

Best Regards,

Xue Ding

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Best Regards,
Xue Ding
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.