Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more
Hi,
Could you please help and explain what I'm doing wrong here?
I've got a two tables with relation based on column "Product Family". Let's assume they both looks:
when I'm building an overview I receive:
How to change this?
Solved! Go to Solution.
Hi @Lesny,
The issue in your Power BI report can be due to a many-to-many relationship between Table 1 and Table 2, both of which are related on the Product Family column. Here's how to fix and address the problem step by step:
Possible Reason for the Incorrect Totals
Possible Fixes and Solutions
Option 1: Use a Bridge Table
ProductFamilyBridge = DISTINCT(
UNION(
SELECTCOLUMNS(Table1, "Product Family", Table1[Product Family]),
SELECTCOLUMNS(Table2, "Product Family", Table2[Product Family])
)
)
Define Relationships:
Remove the direct relationship between Table 1 and Table 2.
Connect Product Family in Table 1 to Product Family in Product Family Bridge.
Connect Product Family in Table 2 to Product Family in Product Family Bridge.
Update Your Matrix:
Use the Product Family field from the Product Family Bridge table in your visual.
Add Sales from Table 1 and Costs from Table 2.
This ensures Power BI aggregates the data correctly without duplication.
Option 2: Use a Composite Model with Measures
If you prefer to avoid creating a bridge table, you can handle the relationship via explicit measures:
TotalCosts = SUM(Table2[Cost])
Use These Measures in Your Matrix:
Add Product Family from either table to your matrix.
Use TotalSales and TotalCosts as the values.
Power BI will correctly compute totals without inflating them.
Option 3: Use the Country Field for Additional Granularity
If Country is important for your analysis, ensure relationships also consider Country:
ProductCountryKey = 'Table'[Product Family] & "-" & 'Table'[Country]
I hope the provided multiple options works for you
If I have resolved your question, please consider marking my post as a solution. Thank you!
A kudos is always appreciated—it helps acknowledge the effort and keeps the community thriving.
Why are your tables with the same structure separate?
Hello. The whole structure is not the same. I simplified the table to show the problem.
Hi @Lesny,
The issue in your Power BI report can be due to a many-to-many relationship between Table 1 and Table 2, both of which are related on the Product Family column. Here's how to fix and address the problem step by step:
Possible Reason for the Incorrect Totals
Possible Fixes and Solutions
Option 1: Use a Bridge Table
ProductFamilyBridge = DISTINCT(
UNION(
SELECTCOLUMNS(Table1, "Product Family", Table1[Product Family]),
SELECTCOLUMNS(Table2, "Product Family", Table2[Product Family])
)
)
Define Relationships:
Remove the direct relationship between Table 1 and Table 2.
Connect Product Family in Table 1 to Product Family in Product Family Bridge.
Connect Product Family in Table 2 to Product Family in Product Family Bridge.
Update Your Matrix:
Use the Product Family field from the Product Family Bridge table in your visual.
Add Sales from Table 1 and Costs from Table 2.
This ensures Power BI aggregates the data correctly without duplication.
Option 2: Use a Composite Model with Measures
If you prefer to avoid creating a bridge table, you can handle the relationship via explicit measures:
TotalCosts = SUM(Table2[Cost])
Use These Measures in Your Matrix:
Add Product Family from either table to your matrix.
Use TotalSales and TotalCosts as the values.
Power BI will correctly compute totals without inflating them.
Option 3: Use the Country Field for Additional Granularity
If Country is important for your analysis, ensure relationships also consider Country:
ProductCountryKey = 'Table'[Product Family] & "-" & 'Table'[Country]
I hope the provided multiple options works for you
If I have resolved your question, please consider marking my post as a solution. Thank you!
A kudos is always appreciated—it helps acknowledge the effort and keeps the community thriving.
Thank you. Solution 1 and 3 helped 🙂
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.