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

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
JamesMartin
New Member

Comparing MTD this month with same period last Month

Hi all,

 

I am wanting to compare this MTD with the same period last month on a cumulative basis.

 

For example:

If today is 13/05/2021, I want the total value for the period 01/04/2021-13/04/2021.

 

I am able to get the running total for the whole previous month but I would like to know how I can get just up until the 13th and then tomorrow for up until the 14th etc.

 

Below is my measure for the whole month:

LastMonthAmount running total in Day =
CALCULATE(
    [LastMonthAmount],
    FILTER(
        ALLSELECTED('Date'[Day]),
        ISONORAFTER('Date'[Day], MAX('Date'[Day]), DESC)
    )
)
 
 
Any help will be greatly appreciated.

 

 

 

1 ACCEPTED SOLUTION
V-lianl-msft
Community Support
Community Support

Hi @JamesMartin ,

 

Please refer to similar threads, hope to help you.

https://community.powerbi.com/t5/Desktop/Dax-Same-period-last-months/m-p/837432 

https://community.powerbi.com/t5/Desktop/Calculation-for-Last-month-Same-Period/m-p/730183 

 

Best Regards,
Liang
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-lianl-msft
Community Support
Community Support

Hi @JamesMartin ,

 

Please refer to similar threads, hope to help you.

https://community.powerbi.com/t5/Desktop/Dax-Same-period-last-months/m-p/837432 

https://community.powerbi.com/t5/Desktop/Calculation-for-Last-month-Same-Period/m-p/730183 

 

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

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 2025 Power BI update to learn about new features.

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.