Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.
Hello Team,
I'm currently working on creating a report on customer churn. Here are some points I need your help in:
I need to calculate the total number of customers I had in the previous year, considering only those customers who had non-zero revenue and volume.
For calculating churn rate, I want to identify customers who generated revenue in the previous year but didn't generate any revenue in the current year. As an example, if we take 2023 as the current year and 2022 as the previous year, a customer with ID 74 would be considered a churned customer.
I also need to figure out how to present the year-on-year calculation for customer churn.
Here is the link to sample dashboard
Please help me out I am really stuck here.
@Anonymous
Hi @Rajan_AN ,
Thanks for the reply from @GilbertQ , please allow me to provide another insight:
1. Create a measure to get the number of customers whose revenue and quantity were not zero in the previous year.
previous year total =
CALCULATE(DISTINCTCOUNT('Sample table'[Customer ID]),FILTER(ALL('Sample table'),'Sample table'[T-DI-A: Calendar Year] = SELECTEDVALUE(' Sample table'[T-DI-A: Calendar Year]) - 1 && 'Sample table'[Total Revenue] <> 0 && 'Sample table'[Total Volume - Liters] <> 0))
2. Create a measure to get the churn customers.
churn customers =
VAR _pre_revenue = CALCULATE(SUM('Sample table'[Total Revenue]),FILTER(ALL('Sample table'),'Sample table'[T-DI-A: Calendar Year] = SELECTEDVALUE('Sample table'[T-DI-A: Calendar Year]) - 1 && 'Sample table'[Customer ID] = MAX('Sample table'[Customer ID]) ))
RETURN
IF(_pre_revenue <> 0 && SUM('Sample table'[Total Revenue]) = 0,1,0)
3. Put churn customers into the filter to show the data with result 1.
If your Current Period does not refer to this, please clarify in a follow-up reply.
Best Regards,
Clara Gong
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Rajan_AN
You can use this DAX pattern from SQL BI for the Lost Customers for what you are looking for: Calculate New, Returning, Lost, and Recovered Customers in #dax - SQLBI