Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

We've captured the moments from FabCon & SQLCon that everyone is talking about, and we are bringing them to the community, live and on-demand. Starts on April 14th. Register now

Reply
Anonymous
Not applicable

Static Yearly Timelines

Hello, 

I have a sort of unique challenge that I am hoping to get some support on. I have a list of reporting deadlines which have static due dates. I would like to add these timelines to my PowerBI dashboard as a guideline for my team. The problem that I am facing is that some of the timelines extend slighly past the current year. For example a report is requested in September of 2023 but due by March 2024. This is a problem as I wanted to write a quick DAX query to go off of the current year but I cant seem to add or subtract a year to reflect these altered due dates. For context I have an excel sheet with the timelines that I am pulling into PowerBI then showing via a Gantt Chart. 

Any advice is welcome, I am fairly new to PowerBI and DAX so it is entirely possible that I am missing something. 

Thanks!

1 ACCEPTED SOLUTION
Anonymous
Not applicable

HI @Anonymous,

I'd like to suggest you write a measure expression to check records and return flag, then use it on the 'visual level filter' to filter records who matched with conditions.

Sample formula: check the current report group of records if they include records that match with configured conditions.

Flag =
VAR msType = "Requested Date"
VAR YearFilter = 2024
VAR currDesc =
    SELECTEDVALUE ( Table1[Description] )
VAR List =
    CALCULATETABLE (
        VALUES ( Table1[Description] ),
        FILTER (
            ALLSELECTED ( Table1 ),
            [milestone] = msType
                && YEAR ( [Date] ) = YearFilter
        )
    )
RETURN
    IF ( currDesc IN List, "Y", "N" )

Regards,

Xiaoxin Sheng

View solution in original post

3 REPLIES 3
Anonymous
Not applicable

Here is some dummy data, I split the chart into three columns one for milestones, one for description, and one for the date (Based off of the milestone). 

LiamNeufeld_0-1715094923310.png

The outliers occur when the dates extend past 2024. My initial thought was to write a dax query to just go off of the current year when viewing as these timelines are repeated yearly. However with the outliers this approach does not work. 

Anonymous
Not applicable

HI @Anonymous,

I'd like to suggest you write a measure expression to check records and return flag, then use it on the 'visual level filter' to filter records who matched with conditions.

Sample formula: check the current report group of records if they include records that match with configured conditions.

Flag =
VAR msType = "Requested Date"
VAR YearFilter = 2024
VAR currDesc =
    SELECTEDVALUE ( Table1[Description] )
VAR List =
    CALCULATETABLE (
        VALUES ( Table1[Description] ),
        FILTER (
            ALLSELECTED ( Table1 ),
            [milestone] = msType
                && YEAR ( [Date] ) = YearFilter
        )
    )
RETURN
    IF ( currDesc IN List, "Y", "N" )

Regards,

Xiaoxin Sheng

Anonymous
Not applicable

Hi @Anonymous ,

Can you please share a pbix or some dummy data that keep the raw data structure with expected results? It should help us clarify your scenario and test to coding formula.

How to Get Your Question Answered Quickly  

Regards,

Xiaoxin Sheng

Helpful resources

Announcements
New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

Check out the March 2026 Power BI update to learn about new features.