Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
I cannot get the time intelligence functions to work. I've been working with Power BI for years, so I do have some experience. Here is some background/detail info:
I've scaled back the data model so there are only two tables: Calendar and Orders. The orders table has an Invoice date that I joined to the calendar table - which is marked as the date table.
Steps I've taken
This validated that I had values for the various invoice dates - basically every Monday thru Friday. And I had a row for every day in the calendar - all 365 days for 2021
When I create the measure:
YTD Sales = CALCULATE([Sales],DATESYTD('Calendar'[Full Date]))
This works - It calculates the correct value for all the sales in 2021
When I create the measure:
MTD Sales = CALCULATE([Sales],DATESMTD('Calendar'[Full Date]))
It does not work; it shows (Blank) when I add it to a Card
I've tried other functions and none of them works for the Month calculations. I'm clueless to what to try next. I would appreciate any help
Solved! Go to Solution.
Hi @JohnFetherolf ,
The first thing to confirm is to check the data model to observe whether the calculated sales of the current month has a corresponding value. If the value is empty, blank will be returned. If this is not the reason, check whether the Full Date field type can count the month.
If it is not the above problem, can you provide test data (delete sensitive information) and more information for me to do further testing.
If you can’t provide further test data, you can check the official documentation for the use of the DATESMTD function and similar solutions, hoping to help you.
Let me know the result immediately, looking forward to your reply.
Best Regards,
Henry
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @JohnFetherolf ,
Check if the solution provided by this link can help you solve the problem.
Let me know the result immediately, looking forward to your reply.
Best Regards,
Henry
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
I found the issue yesterday. My calendar had dates for all of 2021. When I removed the futures, the DATESMTD and TOTALMTD worked. This explains why the DATESYTD and TOTALYTD worked - the calendar did not have future years.
Hi @JohnFetherolf ,
The first thing to confirm is to check the data model to observe whether the calculated sales of the current month has a corresponding value. If the value is empty, blank will be returned. If this is not the reason, check whether the Full Date field type can count the month.
If it is not the above problem, can you provide test data (delete sensitive information) and more information for me to do further testing.
If you can’t provide further test data, you can check the official documentation for the use of the DATESMTD function and similar solutions, hoping to help you.
Let me know the result immediately, looking forward to your reply.
Best Regards,
Henry
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Here is an image the canvas. As you can see, the MTD sales is displayed as (Blank) in the Card visual. However, in the Matrix, you can see there is sales for March (the current month) and in the table, there are several rows with March 2021 dates.
What's the reasoning behind step #3 ?
What do you expect to show on the card visual?
Please post some sample orders data (across multiple months)
Check out the November 2025 Power BI update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!