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

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
mlaura21000
New Member

Churn Month by Month - Urgent

Hi! First post here, am on a bit of an urgent timeline and I don't know how to go about this.

I'm trying to figure out our provider retention. I have multiple providers that have a total amount of sales every month. 

mlaura21000_0-1705934697865.png

 

In a month by month basis, I need to figure out how to classify them into 3 categories: New, Churned, or Existing. These are the rules to do so. If they are present in the current month but were not there the month before they're classified as new. If they are present in the current month but not the following then they are classified as having "churned".
I'm using this formula: ProviderExistsCheck = IF(ISBLANK('table'[ProviderName]), 0, 1)  to check whether they exist and it works fine.

 

Rule breakdown:

mlaura21000_1-1705934736003.png

 

The expected result for each category would look like this:

mlaura21000_2-1705934764051.png

 

mlaura21000_3-1705934786066.png


I would really appreciate any help or guidance I could be given, thank you so much!

1 ACCEPTED SOLUTION
csco90
Regular Visitor

Hello @mlaura21000 , 

 

I used the following data:

csco90_0-1705982127852.png

Created a calculated column:

FirstDayofMonth = DATE(YEAR(Sales[Date]), MONTH(Sales[Date]), 1)
Created the Sales and Sales Prev Measures:
Sales = VAR _sales = SUM(Sales[Sales Amount])
RETURN IF(ISBLANK(_sales), 0, _sales)
-------
Sales Prev = CALCULATE(
            [Sales],
            PARALLELPERIOD(DateTable[Date], -1, MONTH))

csco90_1-1705982254849.png

 

Created the Check forsale and check for sale prev measures:
Check for sale = IF([Sales]>0, 1, 0)
Check for sales prev = IF([Sales Prev]>0, 1, 0)

csco90_2-1705982294653.png

Then check for change measure:

Check for change = VAR _this_month = [Check for sale]
                    VAR _prev_month = IF([Sales Prev]>0, 1, 0)
RETURN _this_month - _prev_month
csco90_3-1705982334215.png

From here is easier to get when a provider churned or is new depending on the sign:

Churn = IF([Check for change] <0, 1, 0)
New = IF([Check for change]>0, 1, 0)
csco90_4-1705982399424.png

Please mark this as the solution if you find it correct!

View solution in original post

2 REPLIES 2
csco90
Regular Visitor

Hello @mlaura21000 , 

 

I used the following data:

csco90_0-1705982127852.png

Created a calculated column:

FirstDayofMonth = DATE(YEAR(Sales[Date]), MONTH(Sales[Date]), 1)
Created the Sales and Sales Prev Measures:
Sales = VAR _sales = SUM(Sales[Sales Amount])
RETURN IF(ISBLANK(_sales), 0, _sales)
-------
Sales Prev = CALCULATE(
            [Sales],
            PARALLELPERIOD(DateTable[Date], -1, MONTH))

csco90_1-1705982254849.png

 

Created the Check forsale and check for sale prev measures:
Check for sale = IF([Sales]>0, 1, 0)
Check for sales prev = IF([Sales Prev]>0, 1, 0)

csco90_2-1705982294653.png

Then check for change measure:

Check for change = VAR _this_month = [Check for sale]
                    VAR _prev_month = IF([Sales Prev]>0, 1, 0)
RETURN _this_month - _prev_month
csco90_3-1705982334215.png

From here is easier to get when a provider churned or is new depending on the sign:

Churn = IF([Check for change] <0, 1, 0)
New = IF([Check for change]>0, 1, 0)
csco90_4-1705982399424.png

Please mark this as the solution if you find it correct!

Ritaf1983
Super User
Super User

Hi @mlaura21000 

please refer to the linked tutorial:
https://www.youtube.com/watch?v=yrdMsES-mXg

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

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

Jan25PBI_Carousel

Power BI Monthly Update - January 2025

Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.

Jan NL Carousel

Fabric Community Update - January 2025

Find out what's new and trending in the Fabric community.