Forum Discussion
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:
And my desired output:
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
- amitchandakSuper 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-solution-8e3eccb41bdaPower BI- Power Query: When I asked you to create common tables: https://youtu.be/PqfGW6pl1Sw