Forum Discussion
Power Query - GA - Date (Yesterday)
Hello,
I have made a query with the google analytics connector that power bi desktop comes with. I'm using the following to filter the dates
#"Filtered Rows" = Table.SelectRows(#"Added Items", each [Date] >= #date(2022, 01, 01) and [Date] <= #date(2022, 02, 27)),
Ι would like to change the date to dynamically be tomorrow. I tried this but it won't work:
#"Filtered Rows" = Table.SelectRows(#"Added Items", each [Date] >= #date(2022, 01, 01) and [Date] <= Date.AddDays(DateTime.LocalNow(),-1))
Any suggestion?
Thank you!
Grigoris
polman4 , for tomorrow it should be +1. Also convert it to date before adding days
#"Filtered Rows" = Table.SelectRows(#"Added Items", each [Date] >= #date(2022, 01, 01) and [Date] <= Date.AddDays(DateTime.Date(DateTime.LocalNow()),1))
2 Replies
- amitchandakSuper User
polman4 , for tomorrow it should be +1. Also convert it to date before adding days
#"Filtered Rows" = Table.SelectRows(#"Added Items", each [Date] >= #date(2022, 01, 01) and [Date] <= Date.AddDays(DateTime.Date(DateTime.LocalNow()),1))
- polman4Helper I