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

Be one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now

Reply
raymond
Post Patron
Post Patron

Month over Month of running totals (cumulative)

Hello Guys,

 

everyone knows the quick measure of running totals or the DAX function YTD. I want to calculate the month over month change of a running total. 

 

Is there a best practice dax expression?

 

1 ACCEPTED SOLUTION
raymond
Post Patron
Post Patron

I have found it out myself. It seems to be working. Here the resolution

 

1. Step: Sum the initial variable "Sales"
sales = SUM( [Sales] )

2. Step: Calculate the cumulated value of "sales"
sales **bleep** =
CALCULATE(
	[Sales];
	FILTER(
		ALLSELECTED([Date]);
		ISONORAFTER([Date]; MAX([Date]); DESC)
	)
)

3. Step: Calculate the percentage difference between 1 and 2
Sales **bleep** MoM% = 
DIVIDE(
    [Sales] ;
    [Sales **bleep**] - [Sales] ;
    0
)

View solution in original post

3 REPLIES 3
raymond
Post Patron
Post Patron

I have found it out myself. It seems to be working. Here the resolution

 

1. Step: Sum the initial variable "Sales"
sales = SUM( [Sales] )

2. Step: Calculate the cumulated value of "sales"
sales **bleep** =
CALCULATE(
	[Sales];
	FILTER(
		ALLSELECTED([Date]);
		ISONORAFTER([Date]; MAX([Date]); DESC)
	)
)

3. Step: Calculate the percentage difference between 1 and 2
Sales **bleep** MoM% = 
DIVIDE(
    [Sales] ;
    [Sales **bleep**] - [Sales] ;
    0
)

Ok then may I ask you to mark your post as solution so others can find it more easily?

JosefPrakljacic
Solution Sage
Solution Sage

So you mean Month-to-Date?

 

Like this here?

If the post was helpful pls mark it as solution and share sume kudos 🙂

2019-09-06 14_09_33-Untitled - Power BI Desktop.png

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!

ArunFabCon

Microsoft Fabric Community Conference 2025

Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.