cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Kkaushik
Frequent Visitor

Power Query Date Filters in Excel

Hello, I am very new to PQ. I have imported huge data from SalesForce. I want to apply 'from and to' date filters on 'transactions date' column but I want users to input the 'from' (and 'to') dates in two separate cells in Excel to refresh my query. I imported the start date as a named range 'FromYTD' and saved as connection only. Then applied to the column as below.

Kkaushik_2-1653980914824.png

 

 

Kkaushik_0-1653980596034.png

Both the transactions column and From YTD is formatted as Date.

The error message I am getting is below. Please help. Thanks

Kkaushik_1-1653980646492.png

 

1 ACCEPTED SOLUTION
Vijay_A_Verma
Super User
Super User

In your formula, make it FromYTD{0} in place pf FromYTD. This will make it refer to first value of FromYTD list.

OR

Don't change formula, in your FromYTD list, right click on List column and drill down. This will make it a single value and you query will work correctly. 

View solution in original post

2 REPLIES 2
Kkaushik
Frequent Visitor

Brilliant! It worked. Thanks

Vijay_A_Verma
Super User
Super User

In your formula, make it FromYTD{0} in place pf FromYTD. This will make it refer to first value of FromYTD list.

OR

Don't change formula, in your FromYTD list, right click on List column and drill down. This will make it a single value and you query will work correctly. 

Helpful resources

Announcements
PBI Sept Update Carousel

Power BI September 2023 Update

Take a look at the September 2023 Power BI update to learn more.

Learn Live

Learn Live: Event Series

Join Microsoft Reactor and learn from developers.

Dashboard in a day with date

Exclusive opportunity for Women!

Join us for a free, hands-on Microsoft workshop led by women trainers for women where you will learn how to build a Dashboard in a Day!

MPPC 2023 PBI Carousel

Power Platform Conference-Power BI and Fabric Sessions

Join us Oct 1 - 6 in Las Vegas for the Microsoft Power Platform Conference.

Top Solution Authors
Top Kudoed Authors