cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted

YTD MTD QTD for past database

I have a simple(maybe stupid) question. Smiley Frustrated

 

According to the definition, Year-to-date (YTD) is a period, starting from the beginning of the current year (either the calendar year or fiscal year) and continuing up to the present day.  And, Month-to-date (MTD) is a period starting at the beginning of the current month and ending at the current date.

 

If we have a database which included the data from 01/03/2010 to 31/12/2016, then what YTD or MTD return when we have expressions like:

 

Profit YTD = CALCULATE ( [Total Profit], DATESYTD ( 'Date'[Date] ) )

 

Profit will be calculated on which dates exactly? 

 

1 ACCEPTED SOLUTION

Accepted Solutions

Re: YTD MTD QTD for past database

@v-yuezhe-msft

So, basically, it takes the last day in current filter context and first of the year of the last day on the current filter context, 

Therefore, if the filter is set on the March 2011, it takes the beginning of 2011 till the end of the current filter which is the March 2011, therefore, it would be "

Jan2011+feb 2011+ Mar2011 

5 REPLIES 5
Moderator v-yuezhe-msft
Moderator

Re: YTD MTD QTD for past database

@elahemeydani,

Please check the example in the following example to learn more about YTD.
1.PNG

Regards,
Lydia

Community Support Team _ Lydia Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Re: YTD MTD QTD for past database

@v-yuezhe-msft

Dear Lydia. can you explain more?

Moderator v-yuezhe-msft
Moderator

Re: YTD MTD QTD for past database

@elahemeydani

Take the left image for example, in Feb 2011, the YTD value equals to  "Jan 2011 sales amount value+Feb 2011 sales amount value", in Mar 2011,  the YTD value equals to  "Jan 2011 sales amount value+Feb 2011 sales amount value +Mar 2011 sales amount value".

Regards,
Lydia

Community Support Team _ Lydia Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Re: YTD MTD QTD for past database

@v-yuezhe-msft

So, basically, it takes the last day in current filter context and first of the year of the last day on the current filter context, 

Therefore, if the filter is set on the March 2011, it takes the beginning of 2011 till the end of the current filter which is the March 2011, therefore, it would be "

Jan2011+feb 2011+ Mar2011 

Moderator v-yuezhe-msft
Moderator

Re: YTD MTD QTD for past database

@elahemeydani,

Yes. You are right.Smiley Happy

Regards,
Lydia

Community Support Team _ Lydia Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.