Forum Discussion
Sort Order based on a dynamic parameter value
- Anonymous1 year ago
Hi sshan21 ,
I did a test for your reference,
Please check it.
Please write a measure, use the switch to determine the value selected by the slicer and the corresponding date range, and then put it in the visual filter to set it to 1.
Measure =
var _select=SELECTEDVALUE('Table'[Column2])
return
SWITCH(
TRUE(),
_select="YTD"&&MAX('Table 2'[Date])>=DATE(2024,1,1),1,
_select="Milk Season"&&MAX('Table 2'[Date])>=DATE(2024,6,1),1,
_select="Fiscal Season"&&MAX('Table 2'[Date])>=DATE(2024,10,1),1,0)
Best Regards,
Sunshine Gu
Hi sshan21 ,
I did a test for your reference,
Please check it.
Please write a measure, use the switch to determine the value selected by the slicer and the corresponding date range, and then put it in the visual filter to set it to 1.
Measure =
var _select=SELECTEDVALUE('Table'[Column2])
return
SWITCH(
TRUE(),
_select="YTD"&&MAX('Table 2'[Date])>=DATE(2024,1,1),1,
_select="Milk Season"&&MAX('Table 2'[Date])>=DATE(2024,6,1),1,
_select="Fiscal Season"&&MAX('Table 2'[Date])>=DATE(2024,10,1),1,0)
Best Regards,
Sunshine Gu