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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
anupampandey
Helper III
Helper III

MTD calculation values not coming correctly

Hi,

 

I am facing a simple problem (probably) which I am unable to resolve.

Problem is while computing the MTD values totals are matching. Below is the screen shot. 

Formula : MTD = TOTALMTD(SUM(COMM_YTD[CALC_RET_COMM]),DATESMTD('Calendar'[DateKey].[Date]))

 

The same method I have used earlier which is working perfectly this time I don't know what happened.

 

MTD_ERROR.PNG

 

 

 

 

 

 

 

 

 

 

 

 

Please help me on this.

4 REPLIES 4
mattbrice
Solution Sage
Solution Sage

My only comment is that using both TOTALMTD and DATESMTD is redundant.  Should either do:

 

MTD = TOTALMTD(SUM(COMM_YTD[CALC_RET_COMM]), Calendar[Date] )  

 

or

 

MTD = CALCULATE(  SUM(COMM_YTD[CALC_RET_COMM]), DATESMTD (Calendar[Date] ) )

Hi, I have used what you suggested still not getting the desired result. Thanks, Anupam

Hi @mattbrice

 

This PBIX file has two versions of the formula that work.

 

https://wgtnpowerbi-my.sharepoint.com/personal/phil_wgtnpowerbi_onmicrosoft_com/_layouts/15/guestacc...

 

Download and have a play to see if it helps.

 

Cheers,

 

 


To learn more about DAX visit : aka.ms/practicalDAX

Proud to be a Datanaut!

anupampandey
Helper III
Helper III

Hi,

 

I am facing a simple problem (probably) which I am unable to resolve.

Problem is while computing the MTD values totals are matching. Below is the screen shot. 

Formula : MTD = TOTALMTD(SUM(COMM_YTD[CALC_RET_COMM]),DATESMTD('Calendar'[DateKey].[Date]))

 

The same method I have used earlier which is working perfectly this time I don't know what happened.

 

MTD_ERROR.PNG

 

 

 

 

 

 

 

 

 

 

 

 

Please help me on this.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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