I have a page with a control filter witch is a list of years (I don't want to use a range period selector but allow users to click on year they want to analyse instead)
I am trying to set 4 scorecard in my GDS that show the value for the selected year, selected year-1, -3 and -maximum.
Here is my dataset :
Date | Value
31/12/2020 | 20
31/12/2019 | 10
31/12/2018 | 5
31/12/2017 | 2
30/09/2016 | 1
For example, in the date control list, if I choose 2019, I should have :
- Score card °1 "Year" : value = 10 (corresponding to 2019)
- Score card °2 "Year-1" : value = 5 (corresponding to 2018)
- Score card °3 "Year-3" : value = 1 (corresponding to 2016)
- Score card °4 "Year-max" : value = 1 (corresponding to 2016 since it is the older year)
Or for example, in date control list, if I choose 2020, I should have :
- Score card °1 "Year" : value = 20 (corresponding to 2020)
- Score card °2 "Year-1" : value = 10 (corresponding to 2019)
- Score card °3 "Year-3" : value = 2 (corresponding to 2017)
- Score card °4 "Year-max" : value = 1 (corresponding to 2016)
I have tried with filters, calculated fields, mixted data, etc... But never find a way to achieve this.
Does anyone have an idea ?
Thanks in advance!