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

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Reply
JT_MSUK
Advocate I
Advocate I

Calculating YoY % Change but exclude next year

Hi, I have three measures setup for the cumulative amount and change:

 

Current Year (YTD)

Members YTD  = CALCULATE([Members],DATESYTD(DATEADD(CalendarTable[Date].[Date],0,Year)))
 
Last Year (Hidden)
Members LYTD = CALCULATE([Members],DATESYTD(DATEADD(CalendarTable[Date].[Date],-1,Year)))
 
 % Change
Members Cumulative % = DIVIDE([Members YTD]-[Members LYTD],[Members LYTD])
 
This is in a parameter, so when I click YTD it shows all my data between 2000-2023, and when I click % Change it'll show the changes over year - all working fine, however the % Change also adds in 2024 with -100%. How do I exclude next year?
1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@JT_MSUK , Try like

 

% Change Members Cumulative % =

if( not(isblank([Members YTD])) ,

DIVIDE([Members YTD]-[Members LYTD],[Members LYTD]), blank())
 

View solution in original post

2 REPLIES 2
amitchandak
Super User
Super User

@JT_MSUK , Try like

 

% Change Members Cumulative % =

if( not(isblank([Members YTD])) ,

DIVIDE([Members YTD]-[Members LYTD],[Members LYTD]), blank())
 

That did the trick, thanks! 🙂

Helpful resources

Announcements
Europe Fabric Conference

Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.

AugPowerBI_Carousel

Power BI Monthly Update - August 2024

Check out the August 2024 Power BI update to learn about new features.

August Carousel

Fabric Community Update - August 2024

Find out what's new and trending in the Fabric Community.