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
Anonymous
Not applicable

How to calculate a percentage per year, not by grand total ?

Hello, 

 

I am beginner in Power BI and I have an issue to calculate a percentage. It is systematically calculated considering all the years whereas I want the percentage of each category per year, can you please help me ? 

Here are my data : 

ValueMoyenLocomotionAnneePercentage I want (% by Total of the year, not by Grand total)
6A Pied

2017

=6/46 = 13%

1Moto

2017

=1/46 =2%

39Voiture

2017

=39/46 = 85%

5A Pied

2018

=5/54 =9%

3Moto

2018

=6%

46Voiture

2018

85%

9A Pied

2019

13%

3A Vélo20194%
2Autre20193%
4Moto20196%
2Transport Public20193%
50Voiture201971%
1A Pied202014%
1Autre202014%
5Voiture202072%
Grand Total : 177   

 

Can you please help me to build the measure to get this info please ?

Thanks a lot, AnSo

1 ACCEPTED SOLUTION
harshnathani
Community Champion
Community Champion

Hi @Anonymous ,

 

You can try these measures.

 

Total Value = SUM('Table'[Value])
 
Percentage =

var _totalvalyear = CALCULATE(SUM('Table'[Value]) , ALLEXCEPT('Table','Table'[Annee]))

RETURN

DIVIDE([Total Value],_totalvalyear)
 
 
1.jpg
 
 

Regards,
Harsh Nathani

Did I answer your question? Mark my post as a solution! Appreciate with a Kudos!! (Click the Thumbs Up Button)

View solution in original post

1 REPLY 1
harshnathani
Community Champion
Community Champion

Hi @Anonymous ,

 

You can try these measures.

 

Total Value = SUM('Table'[Value])
 
Percentage =

var _totalvalyear = CALCULATE(SUM('Table'[Value]) , ALLEXCEPT('Table','Table'[Annee]))

RETURN

DIVIDE([Total Value],_totalvalyear)
 
 
1.jpg
 
 

Regards,
Harsh Nathani

Did I answer your question? Mark my post as a solution! Appreciate with a Kudos!! (Click the Thumbs Up Button)

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

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!

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.