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
Shelley
Continued Contributor
Continued Contributor

DATEADD Function works for some cells, but not others?

I am trying to use the DATEADD function. Ideally, I'd like to add 12 months, and subtract one day, so if anyone can help me with the formula for this, I'd really appreciate it.

 

For now, let's consider the formula MOU_EndDate = DATEADD(Analytics[MOU_Date],12,MONTH). Why does this work for some cells and not others (blanks) as shown? Both columns are set to Date format. ANy help is greatly appreciated. Thanks!

 

CaptureMOU.PNG

 

1 ACCEPTED SOLUTION
Shelley
Continued Contributor
Continued Contributor

I don't know why this wasn't working, but I figured out another way to do what I wanted: MOU_EndDate = EOMONTH(Analytics[MOU_Date],11) - and it works for all cells.

CaptureMOU2.PNG

View solution in original post

2 REPLIES 2
Thiyagu
Helper III
Helper III

I think dateadd works only if there is a date in a date table. Try below

Capture_2.JPG

 

 Column = datecheck[Column1]+365..

 

 

Shelley
Continued Contributor
Continued Contributor

I don't know why this wasn't working, but I figured out another way to do what I wanted: MOU_EndDate = EOMONTH(Analytics[MOU_Date],11) - and it works for all cells.

CaptureMOU2.PNG

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.