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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
kzielinska
Helper I
Helper I

Connecting two tables by multiple fields

Hi!

 

I have 3 tables. Country table has an active relationship with Sales Documents and Billing Documents, and is filtering the Country column in these tables.

 

I need to connect Sales Documents and Billing Documents:

Sales Documents[Country for Billing] -> Billing Documents[Country]

Sales Documents[City for Billing] -> Billing Documents[City]

Sales Documents[Billing Type] -> Billing Documents[Billing Type]

 

I want to count the billing documents for each combination of colums in Sales Documents Table.

Here are the tables:

kzielinska_0-1682503588850.png

kzielinska_1-1682503598774.png

kzielinska_2-1682503607758.png

 

And my desired output:

kzielinska_3-1682503666468.png

 

Can somebody help me with this? 

I can't create even one active relationship between Sales and Billing tables, because they both have already an active relationship with the Country table, which I can't delete. 

 

Thanks in advance! 🙂

 

 

 

1 REPLY 1
amitchandak
Super User
Super User

@kzielinska , According to me you need to create common dimesions. It may be one or more and use that for analysis.

 

I explained the same using DAX and Power query

Power BI- DAX: When I asked you to create common tables: https://youtu.be/a2CrqCA9geM
https://medium.com/@amitchandak/power-bi-when-i-asked-you-to-create-common-tables-a-quick-dax-soluti...

 

Power BI- Power Query: When I asked you to create common tables: https://youtu.be/PqfGW6pl1Sw

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.