Forum Discussion
Anonymous
5 years agoNot applicable
Is it possible to store DateTime.LocalNow() as a scalar variable without creating new column?
Hi there, this problem has had me stuck for a little while. All I'm trying to do is filter the table so that it keeps rows with a date greater than 7 days old. To do so, I'm simply using the [D...
- 5 years ago
Something like this (with your own fields):
= Table.SelectRows(#"previous Step", each Duration.Days( Date.From(DateTime.LocalNow()) - [Date] ) > 7)
HotChilli
5 years agoCommunity Champion
Something like this (with your own fields):
= Table.SelectRows(#"previous Step", each Duration.Days( Date.From(DateTime.LocalNow()) - [Date] ) > 7)Anonymous
5 years agoNot applicable
Ok so the Date.From(DateTime.LocalNow()) has to be called in the Table function? It can't be stored as its own seperate variable and be called like I showed in my example?