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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
jcoolen09
Regular Visitor

subtract values of Column A and Column B

I want to subtract the values from Column A and Column B 

jcoolen09_1-1715361900033.png

For example, for the first row, I would expect the New Column value to be the difference between 16.7 - 5.10, so I would expect a new value in New Column to be 11.6. The basic subtraction measures I've tried are giving results that make no sense to me. It's worth mentioning that Column B is Summed and Column A is not. 

 

jcoolen09_2-1715362058343.png

 

jcoolen09_3-1715362084345.png

 

please help! Thanks!

1 ACCEPTED SOLUTION
jcoolen09
Regular Visitor

solved this by using a Group By in the Transform Data. That seemed to fix up the calculations

View solution in original post

3 REPLIES 3
jcoolen09
Regular Visitor

solved this by using a Group By in the Transform Data. That seemed to fix up the calculations

nvprasad
Solution Sage
Solution Sage

Hi Jcoolen09,

 

Can you try the below measure?

 

Difference = CALCULATE(SUM(Data[A])-SUM(Data[B]))
 
Thank you,
 
If this solution helps, then please consider Accept it as the solution  to help the other members find it more quickly.
Did I answer your question? Mark my post as a solution! Appreciate your Kudos.
Follow me on LinkedIn.

That does not work 

 

jcoolen09_0-1715364637814.png

 

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

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