Forum Discussion
How to create a custom slicer with two options containing range of dates?
- 5 years ago
Anonymous see attached, it is fairly easy to tweak from here. As a best practice, I added a date dimension in the model and added a column to identity dates before and after pandemic and then use this for slicing the data. Also for every date calculation, it is advisable to use date dimension and use a column from it to filter data, like on year, month date etc.
Check my latest blog post Compare Budgeted Scenarios vs. Actuals I would ❤ Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos to whoever helped to solve your problem. It is a token of appreciation!
⚡Visit us at https://perytus.com, your one-stop-shop for Power BI-related projects/training/consultancy.⚡
Anonymous can you explain what these tables are and what your expected output? I have no idea what you are looking for? What trend before and after? What date you have in mind for Pandeming before and after. March 15th, 2020??
Basically these tables are for monthly unemployment claims and unemployment rate. I overlaid these two data sources with my proprietary data which I didn't share. The point is I want to filter my visual's on the basis of a slicer which should have two values, before the pandemic and after the pandemic.
In this case, the slicer contains all the year values. I want to create 2 partitions or 2 values in this slicer. So when I select before the pandemic it should show the trend before Macrh 15th and if I select after it should show the trend after Macrh 15th. Please let me know if its still unclear, I will try my best to explain. Thanks for the help.