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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
MMJen
Helper I
Helper I

Sum of a column

I have a simple table recording Project Managment Information

Each row contains information of a Project Deliverable or resource. 

I have a column which idetnifies which Directorate the deliverable owns the deliverable and one column which holds the total cost of the resoure.

I want to show in a pie or bar chart the total spend per directorate (on an ongoing basis) as this table will continue to be populated during this financial year. 

 

I'm struggling to find the correct formula for this and despite trying various methods I cannot get to see this in what I thought shoudl be straight forward?

 

Can anyone suggest a solution?

1 ACCEPTED SOLUTION

@MMJen

 

Please check your data format and try the solution provided by smoupre, it should be correct.

 

Sum of a column_1.jpg

 

Best Regards,

Herbert

View solution in original post

5 REPLIES 5
Greg_Deckler
Super User
Super User

Given what you describe, you should be able to drag your cost column to the "Values" of the pie chart and your Directorate column to your "Category" for the pie chart and set your "Value" aggregation to "SUM". 


@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...

Hi,

 

Thank you for this.  This does give me a Pie chart per category which is a good start now.  However, it's giving me the Count of the cost not the SUM and i can't see an option under Values or the visualization to give me the SUM here?  Any thoughts?

 

It seems to work on other charts but not this one. 

 

@MMJen

 

Please check your data format and try the solution provided by smoupre, it should be correct.

 

Sum of a column_1.jpg

 

Best Regards,

Herbert

Thanks all, that's it working, great. 

Another lesson learned..

Sounds like your Value came in as Text. You need to convert it to a numeric value (Decimal or Whole Number) either in the Query Editor or in the data model (middle icon on the left).


@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.