cancel
Showing results for 
Search instead for 
Did you mean: 

Fabric is Generally Available. Browse Fabric Presentations. Work towards your Fabric certification with the Cloud Skills Challenge.

Reply
JT_MSUK
Frequent Visitor

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
PBI November 2023 Update Carousel

Power BI Monthly Update - November 2023

Check out the November 2023 Power BI update to learn about new features.

Community News

Fabric Community News unified experience

Read the latest Fabric Community announcements, including updates on Power BI, Synapse, Data Factory and Data Activator.

Power BI Fabric Summit Carousel

The largest Power BI and Fabric virtual conference

130+ sessions, 130+ speakers, Product managers, MVPs, and experts. All about Power BI and Fabric. Attend online or watch the recordings.

Top Solution Authors
Top Kudoed Authors