Forum Discussion
AOT
6 years agoFrequent Visitor
Help with M power query
I need to filter a column have dates between DateTime.FixedLocalNow()) and Date.AddDays((DateTime.FixedLocalNow()), 91)). But I cannot seem to get the right M query script. Please help. T...
- 6 years ago
Hi AOT
Not sure if I've understood your requirement correctly, but I believe this should work as a replacement for your #"Filtered Rows2" step:
#"Filtered Rows2" = Table.SelectRows(#"Extracted Date1", each Date.From([end_date]) = Date.From(DateTime.FixedLocalNow()) or Date.IsInNextNDays(Date.From([end_date]), 91)),
I've used the Date.From() surrounds on the [end_date] column refs so you aren't required to use your "Extracted Date" step if you don't want to.
Remember to remove the comma at the end if this is the last step in your query
Pete