Forum Discussion
dynamically set current date to slicer date selection
- Anonymous4 years ago
Hi kaileena ,
Agree with edhans that there is no way to pass the selection in slicer back to Power Query though.
You may create a measure to dynamically get the offset:
Offset = DATEDIFF(MAX('Table'[Date]),MAX('Dates'[Date]),MONTH)Best Regards,
Eyelyn Qin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hello! I would like my query editor to "read" the value I selected in the slicer. (i need this because i have other columns that calculte the month offset. I want to calculate the month offset with respect to slicer selection)
I hope it is clearer. I will edit the text above.
Power Query cannot see anything in the DAX model nor in the report layer. In DAX, you can use SELECTEDVALUE() or ALLSELECTED() to see what the user has selected. There is no way to pass that back to Power Query though. Power Query to the Model is a one way street - Power Query loads data in.
An exception to that is with a direct query model, but that is only to allow PQ to create SQL code and cannot see the report layer. It just talks to the storage engine.