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

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Reply
QCunity
New Member

Multiple connections between 2 tables

Hello,

I am desperately trying to make multiple connections between different tables. Let me explain:

I have 2 tables with dates and references that I want to join together. These tables are connected through a date table (calendar). Power BI indicates that I can only make one connection, otherwise there will be "ambiguity". Is there a solution to connect multiple columns between the files?

The goal is to be able to link the dates and references together to retrieve information from the second table.

 

Thank you very much for your help

1 ACCEPTED SOLUTION
v-jingzhan-msft
Community Support
Community Support

Hi @QCunity 

 

We can build multiple relationships between two tables, but only one relationship can be active, the other relationships will be inactive. With USERELATIONSHIP function, we can make an inactive relationship active and make it affect the calculation of a DAX formula where the function is used. Only one relationship can be active at a time. 

Active vs inactive relationship guidance - Power BI | Microsoft Learn

 

In your scenario, one approach is to add a dimension table for Reference, just like your date table. Then connect this Reference table to those two tables. 

 

Another approach is to use Merge queries feature in Power Query. If your purpose is to bring matching data from one table into the other table based on two columns, Merge queries feature allows you to select one or more columns as matching columns at the same time, and bring matching data into the first query or into a new query. You can choose to use different types of joins, depending on the output you want. Merge queries overview - Power Query | Microsoft Learn 

 

Hope this will be helpful!

 

Best Regards,
Jing
If this post helps, please Accept it as Solution to help other members find it. Appreciate your Kudos!

View solution in original post

2 REPLIES 2
v-jingzhan-msft
Community Support
Community Support

Hi @QCunity 

 

We can build multiple relationships between two tables, but only one relationship can be active, the other relationships will be inactive. With USERELATIONSHIP function, we can make an inactive relationship active and make it affect the calculation of a DAX formula where the function is used. Only one relationship can be active at a time. 

Active vs inactive relationship guidance - Power BI | Microsoft Learn

 

In your scenario, one approach is to add a dimension table for Reference, just like your date table. Then connect this Reference table to those two tables. 

 

Another approach is to use Merge queries feature in Power Query. If your purpose is to bring matching data from one table into the other table based on two columns, Merge queries feature allows you to select one or more columns as matching columns at the same time, and bring matching data into the first query or into a new query. You can choose to use different types of joins, depending on the output you want. Merge queries overview - Power Query | Microsoft Learn 

 

Hope this will be helpful!

 

Best Regards,
Jing
If this post helps, please Accept it as Solution to help other members find it. Appreciate your Kudos!

Yes, that's very hepful !! thank you so much 😁

Helpful resources

Announcements
July 2024 Power BI Update

Power BI Monthly Update - July 2024

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

PBI_Carousel_NL_June

Fabric Community Update - June 2024

Get the latest Fabric updates from Build 2024, key Skills Challenge voucher deadlines, top blogs, forum posts, and product ideas.

Top Solution Authors
Top Kudoed Authors