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

July 7 - July 17 | Round 2 of the Power BI Dataviz World Championships. Don't miss your chance! Learn more

Reply
Anonymous
Not applicable

Issues Joining Many to Many Cardinality

Hi All, 

 

I am trying to join the two tables in the snippet below but having error. please can i need advice on how to resolve the error. 

 

tnachis_1-1718009450961.png

 

 

Thank you.

3 ACCEPTED SOLUTIONS
ManuelBolz
Responsive Resident
Responsive Resident

Hello @Anonymous,

 

i recommend that you create a bridge table so that you can establish a "1 to n" and an "n to 1" relationship between your tables.


Code Query BrideTableGLAccountNo:

let
    BudgetGL = Table.SelectColumns(#"Budget GL", {"G_L_Account_No"}),
    Actuals = Table.SelectColumns(#"Actuals XXX", {"G_L_Account_No"}),
    Combined = Table.Combine({BudgetGL, Actuals}),
    RemovedDuplicates = Table.Distinct(Combined)
in
    RemovedDuplicates


Best regards from Germany
Manuel Bolz


If this post helped you, please consider Accept as Solution so other members can find it faster.

🤝Follow me on LinkedIn

View solution in original post

Anonymous
Not applicable

Hi,

Thanks for the solution @ManuelBolz  provided, and i want to offer some more information for user to refer to.

hello @Anonymous , as @ManuelBolz  mentioned, you can create a new table as a brigdge table, you can also use calculated table. you can refer to the following solution.

Sample data is the same as you provided.

Create a new table

 

Bridge = DISTINCT(UNION(VALUES('Budget GL'[G_L_Account]),VALUES(Actual[G_L_Account])))

 

vxinruzhumsft_0-1718170399510.png

 

Then create relationships amont the tables

vxinruzhumsft_1-1718170439755.png

And you can refer to the following link.

https://learn.microsoft.com/en-us/power-bi/guidance/relationships-many-to-many#relate-many-to-many-d...

 

 

Best Regards!

Yolo Zhu

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Anonymous
Not applicable

Thanks so muuch! @Anonymous 

 

View solution in original post

4 REPLIES 4
Anonymous
Not applicable

Thanks so much @ManuelBolz 

Anonymous
Not applicable

Hi,

Thanks for the solution @ManuelBolz  provided, and i want to offer some more information for user to refer to.

hello @Anonymous , as @ManuelBolz  mentioned, you can create a new table as a brigdge table, you can also use calculated table. you can refer to the following solution.

Sample data is the same as you provided.

Create a new table

 

Bridge = DISTINCT(UNION(VALUES('Budget GL'[G_L_Account]),VALUES(Actual[G_L_Account])))

 

vxinruzhumsft_0-1718170399510.png

 

Then create relationships amont the tables

vxinruzhumsft_1-1718170439755.png

And you can refer to the following link.

https://learn.microsoft.com/en-us/power-bi/guidance/relationships-many-to-many#relate-many-to-many-d...

 

 

Best Regards!

Yolo Zhu

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Anonymous
Not applicable

Thanks so muuch! @Anonymous 

 

ManuelBolz
Responsive Resident
Responsive Resident

Hello @Anonymous,

 

i recommend that you create a bridge table so that you can establish a "1 to n" and an "n to 1" relationship between your tables.


Code Query BrideTableGLAccountNo:

let
    BudgetGL = Table.SelectColumns(#"Budget GL", {"G_L_Account_No"}),
    Actuals = Table.SelectColumns(#"Actuals XXX", {"G_L_Account_No"}),
    Combined = Table.Combine({BudgetGL, Actuals}),
    RemovedDuplicates = Table.Distinct(Combined)
in
    RemovedDuplicates


Best regards from Germany
Manuel Bolz


If this post helped you, please consider Accept as Solution so other members can find it faster.

🤝Follow me on LinkedIn

Helpful resources

Announcements
FabCon and SQLCon Barcelona 2026

FabCon & SQLCon – Barcelona 2026

Join us in Barcelona for FabCon and SQLCon, the Fabric, Power BI, SQL, and AI community event. Save €200 with code FABCMTY200.

Fabric Community Sticker Design Challenge Barcelona Carousel

Fabric Community Sticker Challenge - Barcelona 2026

If you love stickers, then you will definitely want to check out our community sticker challenge, Barcelona edition!

July Power BI Update Carousel

Power BI Monthly Update - July 2026

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

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.