How to subtract days from a date using Date.AddDays?

Beni2021 1 Reputation point
2021-12-16T23:54:19.843+00:00

Hello,

I am using Date.AddDays in mquery and I am receiving errors in some rows. I want to find a date of birth from the "File_Date" column minus the "Age" column. Anyone know what the problem is? Thank you!

= Table.AddColumn(#"Added Custom", "DOB", each Date.AddDays([File_Date], -([Age]*365.25)))

Not Monitored
Not Monitored
Tag not monitored by Microsoft.
37,794 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Ehren (MSFT) 1,781 Reputation points Microsoft Employee
    2022-01-13T20:13:44.793+00:00

    Try using Date.AddYears instead.

    0 comments No comments