Forum Discussion
Compare volume to constant year
- johnt754 years ago
Super User
Revert back to the DAX you originally had and then check exactly which filters are being applied both when you have 2022 selected in a slicer and when you don't.
If you open the Performance Analyzer from the View ribbon then you can start recording and refresh visuals. Copy the query from the appropriate visual and paste it into DAX Studio. That should show you exactly which columns are being used as filters and you can then include or exclude them from your 2019 measure as appropriate
- amitchandak4 years ago
Super User
setis , Check suggestion from johnt75 .
Please check if this can help
NrCases_2019 =
var _max = maxx(allselected('Date'), 'Date'[Date])
var _year = 2019- Year(_max)
return CALCULATE (
[NrCases], dateadd('Date'[Date], _year, year))- setis4 years ago
Post Partisan
johnt75 thanks for the suggestion, I couldn't make it work like this.
amitchandak this one did it for me. It was a clever and simple way to solve it.
Thanks a lot both of you!