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

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
Anonymous
Not applicable

AddWeeks to date column but February came back with 31 days instead of 28 days

Hi,

I want to add six weeks to my planned date column but for one cell February came back as 31 days, when we know its only 28 days this year.

 

I used : Date.AddWeeks([Planned Sprint],6)

Planned date: 19/11/2019 - Caculated date: 31/02/2020

 

How do I correct 31/02/2020 to 28/02/2020?

 

Thanks

Liz

 

2 ACCEPTED SOLUTIONS
v-juanli-msft
Community Support
Community Support

Hi @Anonymous 

I can't reproduce your problem.

As tested with this funtion, it shows expected value.

3.JPG

 

Best Regards
Maggie
Community Support Team _ Maggie Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

edhans
Super User
Super User

It isn't possible to have a 31/2/2020 date. February never has 30 or more days. But Feb 29, 2020 is legit. You can see at the top I'm using the same Date.AddWeeks() function.

 

2020-03-17 20_28_08-Untitled - Power Query Editor.png



Did I answer your question? Mark my post as a solution!
Did my answers help arrive at a solution? Give it a kudos by clicking the Thumbs Up!

DAX is for Analysis. Power Query is for Data Modeling


Proud to be a Super User!

MCSA: BI Reporting

View solution in original post

4 REPLIES 4
Anonymous
Not applicable

Hi,

 

Sorry I look at the wrong data set. I've sorted it out now.

 

Thanks for your time and assisstance.

Liz 

edhans
Super User
Super User

It isn't possible to have a 31/2/2020 date. February never has 30 or more days. But Feb 29, 2020 is legit. You can see at the top I'm using the same Date.AddWeeks() function.

 

2020-03-17 20_28_08-Untitled - Power Query Editor.png



Did I answer your question? Mark my post as a solution!
Did my answers help arrive at a solution? Give it a kudos by clicking the Thumbs Up!

DAX is for Analysis. Power Query is for Data Modeling


Proud to be a Super User!

MCSA: BI Reporting
v-juanli-msft
Community Support
Community Support

Hi @Anonymous 

I can't reproduce your problem.

As tested with this funtion, it shows expected value.

3.JPG

 

Best Regards
Maggie
Community Support Team _ Maggie Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

artemus
Microsoft Employee
Microsoft Employee

I'm not sure I follow.

 

First there are 29 days in Febuary this year, not 28.

 

Second, November 11th 2019 + 6 week = December 31st 2019, or 31/12/2019

 

If you are sure you are seeing a Febuary 31st date. Is this possibly a string instead of a date? Power Bi will reject any attempt to create that date.

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

September Power BI Update Carousel

Power BI Monthly Update - September 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Kudoed Authors