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
Scotty89
New Member

Date.Addmonths... Not recognised?? What am I doing wrong?

I am using Power Query (actually for Excel for this instance, but also for Power BI).

 

I have

  • A date column [Forecast Month]
  • An integer column [Add Month]

I want to create a calculated column, a second date field, by adding the integer (in months) to the original date column.

Please note: I am in Australia, the dates are formatted dd/mm/yyyy

 

The formula I have tried is

Date.Addmonths([Forecast Month],[Add Month])

However Power Query is throwing this error code:

 

Expression.Error: The name 'Date.Addmonths' wasn't recognized.  Make sure it's spelled correctly.

 

I sourced this formula directly from the "learn about Power Query formulas" link that is inside Power Query formula window... What am I doing wrong?

 

Forecast1.JPGForecast2.JPG

1 ACCEPTED SOLUTION
Scotty89
New Member

Nevermind....

 

I tried Date.AddDays, worked. Tried Date.AddYears, worked... Date.AddQuarters... worked.

 

Turns out the formula is CASE SENSITIVE. It needs to be Date.AddMonths not Date.Addmonths Smiley Mad

View solution in original post

1 REPLY 1
Scotty89
New Member

Nevermind....

 

I tried Date.AddDays, worked. Tried Date.AddYears, worked... Date.AddQuarters... worked.

 

Turns out the formula is CASE SENSITIVE. It needs to be Date.AddMonths not Date.Addmonths Smiley Mad

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.