Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
i have Date from 1 Jan 2020 to 16 Feb 2023 And Sales and i want a bar chart which shows rolling 12 Month for each month for current selection and previousYear Same Month.
My Output should be like this
Hello,
In the script, you can try to add a "calendar type" table which look like this :
Month_Year_Link | Calendar Type | Month_Year |
Jan 2023 | Rolling 12 CY | Jan 2023 |
Dec 2022 | Rolling 12 CY | Jan 2023 |
Nov 2022 | Rolling 12 CY | Jan 2023 |
Oct 2022 | Rolling 12 CY | Jan 2023 |
Sep 2022 | Rolling 12 CY | Jan 2023 |
Aug 2022 | Rolling 12 CY | Jan 2023 |
Jul 2022 | Rolling 12 CY | Jan 2023 |
Jun 2022 | Rolling 12 CY | Jan 2023 |
May 2022 | Rolling 12 CY | Jan 2023 |
Apr 2022 | Rolling 12 CY | Jan 2023 |
Mar 2022 | Rolling 12 CY | Jan 2023 |
Feb 2022 | Rolling 12 CY | Jan 2023 |
Jan 2022 | Rolling 12 PY | Jan 2023 |
Dec 2021 | Rolling 12 PY | Jan 2023 |
Nov 2021 | Rolling 12 PY | Jan 2023 |
Oct 2021 | Rolling 12 PY | Jan 2023 |
Sep 2021 | Rolling 12 PY | Jan 2023 |
Aug 2021 | Rolling 12 PY | Jan 2023 |
Jul 2021 | Rolling 12 PY | Jan 2023 |
Jun 2021 | Rolling 12 PY | Jan 2023 |
May 2021 | Rolling 12 PY | Jan 2023 |
Apr 2021 | Rolling 12 PY | Jan 2023 |
Mar 2021 | Rolling 12 PY | Jan 2023 |
Feb 2021 | Rolling 12 PY | Jan 2023 |
So here for Jan 2023 for exemple, the calculations will be done on all month we want, here Rolling 12 Month. Thus, it will simplify things and in the measures it will be enough to put :
Sum({<[Calendar Type]={'Rolling 12 CY'}>} Sales)
and
Sum({<[Calendar Type]={'Rolling 12 PY'}>} Sales)
Best regards,
Steven