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

Learn from the best! Meet the four finalists headed to the FINALS of the Power BI Dataviz World Championships! Register now

Reply
mukeshmutreja
Microsoft Employee
Microsoft Employee

Multiple relations

How to create multiple column relations between two tables.

 

For Ex:

 

I have two tables:

 

1. Product Group table

 

CompanyProduct GroupProduct
APG1ITM1
APG1ITM2
BPG2ITM1

2. Sales Table

 

CompanyProductSales Amount
AITM1100
AITM2200
BITM1

300

 

Requirement is to fetch the Product group from table 1 based upon company and product values from table 2.

 

1 ACCEPTED SOLUTION
itayrom
Resolver II
Resolver II

In Power BI's model, a relationship can be created between two tables only by connecting a single column from each one.

Therefore, what you should do is add a key column to each of the tables that concatenates the Company and Product columns values for each row. You can do this either via a DAX expression or in Power Query.

 

For example, you can create a calculated column in each table using the following DAX expressions-

In the Product Group table-

Key = 'Product Group'[Company] & "|" & 'Product Group'[Product]

 

In the Sales table-

ProductGroupFK = 'Sales'[Company] & "|" & 'Sales'[Product]

 

 

And then create a relationship between them.

View solution in original post

1 REPLY 1
itayrom
Resolver II
Resolver II

In Power BI's model, a relationship can be created between two tables only by connecting a single column from each one.

Therefore, what you should do is add a key column to each of the tables that concatenates the Company and Product columns values for each row. You can do this either via a DAX expression or in Power Query.

 

For example, you can create a calculated column in each table using the following DAX expressions-

In the Product Group table-

Key = 'Product Group'[Company] & "|" & 'Product Group'[Product]

 

In the Sales table-

ProductGroupFK = 'Sales'[Company] & "|" & 'Sales'[Product]

 

 

And then create a relationship between them.

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

February Power BI Update Carousel

Power BI Monthly Update - February 2026

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.