Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi,
I have a date defintion table on with dates which correspond to the financial year and period they fall in.
Data Table:
Date
GBP Value
Period Definition table:
Date
Financial Year
Period
(Key is by date)
I've been using this fine to slice reports by financial year and period.
However on some reports I have to have two slicers; one is a single select period slicer so visualisations display data for the selected period and a second slicer which is a range slicer so it displays year start to selected period data. However having the users change two slicers isn't ideal...
What I'm trying to do it make it so when a user selects a period in the single select dropdown, rather than needing to change the second filter my visualisations use some form of a <= measure on the period slicer.
Above is what I'm trying to achieve without the need for the range slicer.
(I do have other columns and slicers that come into play but left them out for simplicity)
Any thoughts?
Thanks!
Solved! Go to Solution.
Hi @Anonymous ,
I'm not sure I got you. You want to change the period slicer and show the data which is less than the selected period. Do I understand correctly? If so, you could reference my steps.
Table = SUMMARIZECOLUMNS('Period Definition'[Period])
Measure = var sele = SELECTEDVALUE('Period Slicer'[Period]) var result = CALCULATE(SUM(Data[GBP Values]),FILTER('Period Definition','Period Definition'[Period] <= sele)) return IF(ISFILTERED('Period Slicer'[Period]),result, SUM(Data[GBP Values]))
Best Regards,
Xue Ding
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Anonymous ,
I'm not sure I got you. You want to change the period slicer and show the data which is less than the selected period. Do I understand correctly? If so, you could reference my steps.
Table = SUMMARIZECOLUMNS('Period Definition'[Period])
Measure = var sele = SELECTEDVALUE('Period Slicer'[Period]) var result = CALCULATE(SUM(Data[GBP Values]),FILTER('Period Definition','Period Definition'[Period] <= sele)) return IF(ISFILTERED('Period Slicer'[Period]),result, SUM(Data[GBP Values]))
Best Regards,
Xue Ding
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Thanks, your answer got me 99% of the way there.
I just needed a second measure replacing 'Period Definition'[Period] <= sele with 'Period Definition'[Period] = sele then a table filter for the second table where Measure 2 IS NOT BLANK got the desired result.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
109 | |
98 | |
77 | |
66 | |
54 |
User | Count |
---|---|
144 | |
104 | |
100 | |
86 | |
64 |