Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
Hello everyone! I'm using the datesMTD calculation to get Month To Date values. First, I used it with one year of data, and it worked. Now, I've tried using it for 13 years of information, and I'm getting the following error:
What could be wrong with it? What should I fix on my code (find it below) or in my database to fix this error? (both tables are joined by a Key that generates a many-to-many relationship)
Solved! Go to Solution.
@julsr Try using below DAX
DAX
TotalMTDValue =
CALCULATE(
SUM(database[amount]),
DATESMTD(DatesTable[Date])
)
Proud to be a Super User! |
|
Hi @julsr ,
At my knowledge, using time intelligence functions requires the date table to be continuous and non-repeating date range.
Does your date table contain duplicate dates? If so, please try using the calendar() function to create a date table.
Best Regards,
Wearsky
@julsr Try using below DAX
DAX
TotalMTDValue =
CALCULATE(
SUM(database[amount]),
DATESMTD(DatesTable[Date])
)
Proud to be a Super User! |
|
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 39 | |
| 37 | |
| 33 | |
| 32 | |
| 29 |
| User | Count |
|---|---|
| 132 | |
| 88 | |
| 82 | |
| 68 | |
| 64 |