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!Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.
First, let me apologize as this is probably super simple, but I have been trying and reading and trying to no avail. I am trying to get a number of repeat customers based on two measures; Total Customers and Total Orders where total orders is > 1. My table consists of one order per record. Below is what I have. Thank you in advance!
Solved! Go to Solution.
It does take some getting used to but what you need to do is build the list of customers that match your criteria ([Total Orders] > 1) and use that list as the argument in the calculate. We do that using FILTER over the list of unique customers (Cutomer ID, Customer Number, Customer Key, whatever it is in your model).
It looks like this:
Repeat Customers =
CALCULATE (
[Total Customers],
FILTER ( VALUES ( Customer[CustomerKey] ), [Total Orders] > 1 )
)
You can simplify it by just counting the list of filtered customers like this:
Repeat Customers =
COUNTROWS ( FILTER ( VALUES ( Customer[CustomerKey] ), [Total Orders] > 1 ) )
It does take some getting used to but what you need to do is build the list of customers that match your criteria ([Total Orders] > 1) and use that list as the argument in the calculate. We do that using FILTER over the list of unique customers (Cutomer ID, Customer Number, Customer Key, whatever it is in your model).
It looks like this:
Repeat Customers =
CALCULATE (
[Total Customers],
FILTER ( VALUES ( Customer[CustomerKey] ), [Total Orders] > 1 )
)
You can simplify it by just counting the list of filtered customers like this:
Repeat Customers =
COUNTROWS ( FILTER ( VALUES ( Customer[CustomerKey] ), [Total Orders] > 1 ) )
This worked! Thank you so much!!!!
You can read more about the error here
https://www.sqlbi.com/articles/solving-errors-in-calculate-filter-arguments/
try this
CALCULATE([TOTAL Customers],FILTER(ALL(Yourtable),[TOTAL Order]>1))
Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!
Check out the September 2025 Power BI update to learn about new features.