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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends September 15. Request your voucher.

Reply
oliverome
Regular Visitor

DATEADD doesn't display dates in future

I'm trying to create a column with a DAX formula that calculates a new date based on dates in another column. For context, I am calculating when a a device needs servicing. If the last servicing was 01-01-2022, it needs servicing again on 01-01-2025. 

 

In short, I want to do:

new_date = old_date + 3 years.

 

I used the following formula: 

calibration_due = DATEADD('EO_data'[last_calibration].[Date], 3, YEAR)
 

However, this only gives an output if the new servicing date is already in the past. That can be the case for some unused devices. The rows where the new servicing date is in the future, remain blank. I need the future dates as well. How do I do that?

 

1 ACCEPTED SOLUTION
tharunkumarRTK
Super User
Super User

Dateadd function doesnot work for you as it takes the list of available dates from your date table. 
For your requirement you can try creating a calculated column using the below pattern 
DATE(Year(DateTable[Date]) + 3, Month(DateTable[Date]), Day(DateTable[Date])

you can also do this in power query using Date.AddYears function 
https://learn.microsoft.com/en-us/powerquery-m/date-addyears

View solution in original post

2 REPLIES 2
tharunkumarRTK
Super User
Super User

Dateadd function doesnot work for you as it takes the list of available dates from your date table. 
For your requirement you can try creating a calculated column using the below pattern 
DATE(Year(DateTable[Date]) + 3, Month(DateTable[Date]), Day(DateTable[Date])

you can also do this in power query using Date.AddYears function 
https://learn.microsoft.com/en-us/powerquery-m/date-addyears

Thank you! I had tried that before, but I see I put the +3 in the wrong place. It works now.

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

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