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

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
BlueNote
Frequent Visitor

Running Total % Change with no change in fist year

I need a DAX function that calculates the % change between the bars on this running total chart. The first bar will not have a change because the prior period needs to start at zero no matter what range of years the user selects. 

 

Here is my running total function

running test cy = IF (
    [Actuals],
    CALCULATE (
        [Actuals],
        FILTER (
            ALLSELECTED ( 'Calendar'[Date] ),
            ISONORAFTER ( 'Calendar'[Date], MAX ( 'Calendar'[Date] ), DESC )
        )
    )
)

Here is the current bar chart and some mark up indicating what I am looking to do.

 

2008 % Change = (.3-0) / 0) = 0 or N/A

2009 % Change = (.7-.3) / .3) = 133% 

2010 % Change = (1-.7) / .7 = 43%

so on and so forth up to the last year

 

pic one.PNG

 

Thanks in Advance for any help!

 

 

2 REPLIES 2
amitchandak
Super User
Super User

@BlueNote , Based on what I got

YOY % will the change % even in case of cummulative 

 

 

Create measures like this year vs last year (or as var ), by any og the one method

 

examples

YTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESYTD('Date'[Date],"12/31"))
Last YTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESYTD(dateadd('Date'[Date],-1,Year),"12/31"))

 

This year Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESYTD(ENDOFYEAR('Date'[Date]),"12/31"))
Last year Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESYTD(ENDOFYEAR(dateadd('Date'[Date],-1,Year)),"12/31"))

 

 

This Year = CALCULATE(sum('Table'[Qty]),filter(ALL('Date'),'Date'[Year]=max('Date'[Year])))
Last Year = CALCULATE(sum('Table'[Qty]),filter(ALL('Date'),'Date'[Year]=max('Date'[Year])-1))

 

diff = [This Year]-[Last Year ]
diff % = divide([This Year]-[Last Year ],[Last Year ])

 

 

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Thanks for your reply.

 

I tried using simple YoY % change but that doesn't work because this is % change of a cumulative amount. Also the first year needs to start with the prior year = 0 in all date ranges selected by the user. 

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.