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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
mohammedkhan
Helper I
Helper I

Percentage growth in 5 years

I have Country Name and Years columns i want to show the Growth for each country in last 5 years 

Capture.PNG

1 ACCEPTED SOLUTION
v-xicai
Community Support
Community Support

Hi mohammedkhan,

 

According to your description, I create sample data to reproduce the scenario. You can implement your demand following steps below.

 

Firstly, convert the column 2012-2017 to row data like picture below. Named the new column "Year", and change its data type to Whole Number.

6.jpg

 

 

 

 

7.jpg

 

 

 

 

 

 

 

 

 

Then, create measure named Year Growth to get the Growth for each country in last 5 years.

 

Year Growth =

VAR _previous = CALCULATE(SUM(Table1[Value]),FILTER(ALLSELECTED(Table1), 'Table1'[Country Name]=MAX(Table1[Country Name])&&Table1[Year] = MAX(Table1[Year]) -1))

VAR _current = CALCULATE(SUM(Table1[Value]),FILTER(ALLSELECTED(Table1),'Table1'[Country Name]=MAX(Table1[Country Name])&&Table1[Year] =MAX(Table1[Year])))

return

IF(_previous<>BLANK(),DIVIDE(_current,_previous,0)-1,BLANK())

 

Choose the table visual to display the result.

 

8.png

 

 

 

 

 

 

 

 

 

 

Here is my test pbix file link: https://qiuyunus-my.sharepoint.com/:u:/g/personal/pbipro_qiuyunus_onmicrosoft_com/EfAtmoNdJf9Cl34-EE...

 

Best Regards,

Amy

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

View solution in original post

1 REPLY 1
v-xicai
Community Support
Community Support

Hi mohammedkhan,

 

According to your description, I create sample data to reproduce the scenario. You can implement your demand following steps below.

 

Firstly, convert the column 2012-2017 to row data like picture below. Named the new column "Year", and change its data type to Whole Number.

6.jpg

 

 

 

 

7.jpg

 

 

 

 

 

 

 

 

 

Then, create measure named Year Growth to get the Growth for each country in last 5 years.

 

Year Growth =

VAR _previous = CALCULATE(SUM(Table1[Value]),FILTER(ALLSELECTED(Table1), 'Table1'[Country Name]=MAX(Table1[Country Name])&&Table1[Year] = MAX(Table1[Year]) -1))

VAR _current = CALCULATE(SUM(Table1[Value]),FILTER(ALLSELECTED(Table1),'Table1'[Country Name]=MAX(Table1[Country Name])&&Table1[Year] =MAX(Table1[Year])))

return

IF(_previous<>BLANK(),DIVIDE(_current,_previous,0)-1,BLANK())

 

Choose the table visual to display the result.

 

8.png

 

 

 

 

 

 

 

 

 

 

Here is my test pbix file link: https://qiuyunus-my.sharepoint.com/:u:/g/personal/pbipro_qiuyunus_onmicrosoft_com/EfAtmoNdJf9Cl34-EE...

 

Best Regards,

Amy

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 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.

Top Solution Authors