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
Domenick
Helper IV
Helper IV

Help subtracting columns between two joined tables

 

I've simplified my problem so that all I need to do is subtract a column in one table from a column in another table. There is a one-to-one relationship between the two tables, so I don't see why this is so complicated. It still won't let me subtract without aggregation. This is really frustrating. Can anyone help?

1 ACCEPTED SOLUTION
JarroVGIT
Resident Rockstar
Resident Rockstar

If there is a one-to-one relation, then you can add a calculated column like this:

 

CalcColumn = Table1[BaseColumn] - RELATED(Table2[SubtractColumn])

 

That should work. 

Kind regards

Djerro123

-------------------------------

If this answered your question, please mark it as the Solution. This also helps others to find what they are looking for.

Keep those thumbs up coming! 🙂

 





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




View solution in original post

6 REPLIES 6
CoreyP
Solution Sage
Solution Sage

Can you just merge the two tables together? Then just add a calc column of: [Column1] - [Column2]

 

I'm a little confused. The merging feature doesn't seem to work like I'm expecting. After it completes the merge, both tables appear unchanged. And there's no new table or anything. If you've tried this before, can you tell me what I'm missing? @CoreyP 

@JarroVGIT 's solution is simpler than mine. Use his! 😉

Thanks for the suggestion; I'll give it a shot. It just seems like a really simple operation that I should be able to do if the tables are joined properly, so it's frustrating that it doesn't behave as expected.

JarroVGIT
Resident Rockstar
Resident Rockstar

If there is a one-to-one relation, then you can add a calculated column like this:

 

CalcColumn = Table1[BaseColumn] - RELATED(Table2[SubtractColumn])

 

That should work. 

Kind regards

Djerro123

-------------------------------

If this answered your question, please mark it as the Solution. This also helps others to find what they are looking for.

Keep those thumbs up coming! 🙂

 





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




Thank you so much. This is such a relief @JarroVGIT 

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.