Hello,
I have a dataset with a “date” variable and I would like to dynamically assign the start date of my graph as the last date in my dataset -20 years. I can use an ods-adv-analysis to obtain the latest date in my dataset, but I can't subtract 20 years from it. Furthermore, I can hardcode the start date, but not using a dynamic variable:
<div
ods-adv-analysis="maxdate"
ods-adv-analysis-context="pibcroissancetrimestre"
ods-adv-analysis-select="max(date) as maxdate"
>
{{last_date = maxdate[0].maxdate; ""}}
{{last_date}}
{{
pibcroissancetrimestre.parameters['q.from_date.date'] =
'date>=2005-09-30T00:00:00+00:00 ';
""}}Can someone help me fix this code?
Thanks in advance
Nathan