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

The Power BI Data Visualization World Championships is back! It's time to submit your entry. Live now!

Reply
Anonymous
Not applicable

calculate sum based on another column distinct values

Hi Team,

     how to find sum using another column distinct values, after unpivoting the the columns im getting results like this

Capture1.PNG

 

i want to sum of Total column,    i need result is 3.7  but im getting 11.1

calculate the sum based on another column distinct values  How to solve this?

 

 

 

Thanks,

Ranga

 

 

 

 

1 ACCEPTED SOLUTION
Anonymous
Not applicable

@Anonymous    it's work but i need other column to build the table

 

i'm looking measure only i have used below measure

 

Total sales = SUMX(DISTINCT('Table'[Category]),MAX('Table'[Total]))
 
it's work for me
 
Thanks

View solution in original post

2 REPLIES 2
Anonymous
Not applicable

I think what you want can be done in Power Query - Transform - Group by.

 

jacobs_5-1623930855751.png

 


When I do that I get the results you seek: 

 

jacobs_6-1623930855753.png

 

I used these settings for the step:

 

jacobs_7-1623930855755.png

 

Let me know if it works

 

Anonymous
Not applicable

@Anonymous    it's work but i need other column to build the table

 

i'm looking measure only i have used below measure

 

Total sales = SUMX(DISTINCT('Table'[Category]),MAX('Table'[Total]))
 
it's work for me
 
Thanks

Helpful resources

Announcements
December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.