Reputation: 1
I am trying to do a date diff between Today and COMPLETE PAPERWORK RECEIVED IN IMPL, but also need to add an IF clause if the COMPLETE PAPERWORK RECEIVED IN IMPL is null, to give it a 0. I think my custom column is excluding null records because of this formula so trying to add a condition to accommodate for those rows. Thanks!
= Table.AddColumn(#"Removed Duplicates", "Days in E&B", each (Duration.Days(Date.From(DateTime.LocalNow())-Date.From([COMPLETE PAPERWORK RECEIVED IN IMPL]))))
Upvotes: 0
Views: 29
Reputation: 21298
just wrap your statement with an if ... then ... else
= Table.AddColumn(#"Removed Duplicates", "Days in E&B", each
if [COMPLETE PAPERWORK RECEIVED IN IMPL] = null then 0 else
(Duration.Days(Date.From(DateTime.LocalNow())-Date.From([COMPLETE PAPERWORK RECEIVED IN IMPL]))))
Upvotes: 1