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

A new Data Days event is coming soon! This time we’re going bigger than ever. Fabric, Power BI, SQL, AI and more. Don't miss out.

Reply
Alex_192
Frequent Visitor

How to join 2 tables with different columns to match (and within each different infos)

Hello everyone,

 

I am quite new on PowerBi but despite some hours of youtube tutoriel and reading on the net, I can't manage to join my two tables in Power BI..

I would really appreciate if someone could help me 🙂

 

Let me explain:

 

I have a 1st table (invoice database) with invoice where I have 1 line = 1 invoice with:

- salesman name (A, B, C, D, E, G) - here the salesman "G" is not in the budget table

- product name (Pdt1, Pdt2, Pdt3, Pdt4, Pdt 6) - here the Pdt 6 is not in the budget table

- sales (in value)

- quarter

 

My second table with the budget where I have 1 line = 1 quarterly budget per product per salesman with:

- salesman (A, B, C, F) - here the "F" salesman is not in my invoice database

- product name (Pdt1, Pdt2, Pdt3, Pdt4, Pdt 5) - here the Pdt 5 is not in the invoice database

- quarter

- Budget (in value)

 

How do I join those 2 tables to get:

per salesman (A, B, C, D, E, F and G) and per product name (Pdt1, Pdt 2, Pdt 3, Pdt 4, Pdt5 and Pdt 6) the sales realized and budget per quarter ?

(I can't manage to have the full list of salesman + the full list of product name with the correct allocation of both sales & budget)

 

Thank you very much for you help!

 

Alex

1 ACCEPTED SOLUTION

Perfect thank you it works!

View solution in original post

4 REPLIES 4
spuder
Resolver IV
Resolver IV

Hi @Alex_192

 

as far as I can see you have two fact tables with different values.

 

What you need are two more dimension tables.

 

The first one is a table with all salesmen and the second one with all products.

 

Connect BOTH with BOTH fact tables salesmen <-> salesmen and product <-> product

 

You should now be able to use salesmen from your dimension table as your category for visuals and the same with products.

Hello Spuder,

 

Thanks for your prompt answer !

 

How would you connect those dimension table with the "invoice" and "budget" table, I probalby misunderstood something as I am creating a loop (one with salesmen one with product) between invoince and budget table

 

Thanks

 

Alex

 

 

At the beginning just create two tables.

 

 

DimSalesmen

 

[Sales Member]

Salesman a

Salesman b

Salesman c

...

 

DimProducts

 

[ProductName]

Product a

Product b

Product c

...

 

 

Both tables only have one column.

 

Now create a relationship between The Column [ProductName] in DimProducts and the Product Columns in the existing fact tables. Do the same with Salesmen.

 

Now create a matrix visual and set [ProductName] column to Rows and [Sales Member] Column to rows, too.

 

Voila 

Perfect thank you it works!

Helpful resources

Announcements
May Power BI Update Carousel

Power BI Monthly Update - May 2026

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

Fabric SQL PBI Data Days

Data Days 2026 coming soon!

Sign up to receive a private message when registration opens and key events begin.

New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

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.