- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

Dynamic Years
Hello Experts,
I would need your support in a report that has a special requirement on showing years dynamically.
Description of Requirement:
In the charts of the reports, there should ALWAYS be shown whether current year + 5 years of data / current year + 7 years of data (depending on the report page, one is for the +5 years and one for the +7 years variant).
The starting year should always be derived from the Previous-version which is connected to the "Version"-Dropdown.
This can be e.g. version: "January 2024" -> previous version: "December 2023" -> 2023
Lets take an example - If now February 2024 is chosen in the dropdown, the years shown in the charts should be...
5-years view --> 2024 - 2029, 7-years view --> 2024 - 2031.
Now how could we achieve this behavior in the charts? Where would you start and which logic should be used?
Right now, the years are filtered manually in fixed year ranges, e.g. 2024 - 2031, which of course leads to issues as its never possible to go back in time later then 2024 and also, its a manual effort each year to change the time range.
Would really appreciate any feedback about this topic.
Thank you & have a nice day.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

You could create a couple of measure like
5 Years Visible =
VAR CurrentYear =
MAX ( 'Date'[Year] )
VAR ChosenYear = [Previous version]
VAR Result =
IF ( CurrentYear >= ChosenYear && CurrentYear <= ChosenYear + 5, 1 )
RETURN
Result
where [Previous Version] is a measure which returns the desired start year according to your logic.
Apply this measure as a filter on the visuals set to show only when the value is 1.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

You could create a couple of measure like
5 Years Visible =
VAR CurrentYear =
MAX ( 'Date'[Year] )
VAR ChosenYear = [Previous version]
VAR Result =
IF ( CurrentYear >= ChosenYear && CurrentYear <= ChosenYear + 5, 1 )
RETURN
Result
where [Previous Version] is a measure which returns the desired start year according to your logic.
Apply this measure as a filter on the visuals set to show only when the value is 1.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

Hi @Johann_32,
You would need a disconnected calendar table or at least a table with years to achieve that. You can check the solution for previous N periods in the video below and modify the logic to future years:
https://youtu.be/d8Rm7dwM6gc?si=cebTXDnQP9pWTIpB

Helpful resources
Subject | Author | Posted | |
---|---|---|---|
07-18-2024 08:12 AM | |||
Anonymous
| 07-16-2024 04:14 AM | ||
01-30-2025 08:30 AM | |||
06-10-2024 11:18 AM | |||
02-28-2025 02:13 PM |
User | Count |
---|---|
122 | |
104 | |
83 | |
52 | |
45 |