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
BigKev
Helper III
Helper III

Sum and then get the max value

Hi All,

 

I have this use case, where I need to sum the value of the Category, and then show the max value. Does anyone know how I can achieve this using the calculated measure?

 

This is my data Set

CategoryProductValue
ABook1
A

Furniture

2
BBook3
BFurniture4
CBook5
CFurniture6

 

Initially, I would need to sum all value by category. The result should look like this

CategoryValue
A3
B7
C11

 

And then I need to show the value of "11" as a KPI, as it is the max value of all categories. 

 

Please help.

 

Cheers,

Kev

1 ACCEPTED SOLUTION

Hi,

Download my PBI file from here.

Hope this helps.

Untitled.png


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

View solution in original post

3 REPLIES 3
Ashish_Mathur
Super User
Super User

Hi,

Write these measures

Total = SUM(Data[Value])

Max of total = MAXX(VALUES(Data[Category]),[Total])

Drag Max of total to your vosual.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

Hey  Ashish,

 

Thanks for the prompt reply.

 

I have tried the dax measure that you have provided. However, it give me the total values for all category instead. In this case it is "21". Am I missing anything?

 

Cheers,

Kev

Hi,

Download my PBI file from here.

Hope this helps.

Untitled.png


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

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.

Top Solution Authors