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

To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.

Reply
Henry1943
Frequent Visitor

How to combine two table into one

I want to combine the two table as below:

Table 1

Product nameversiondateQuantity1Quantity2
H12317/7/20173 
H12327/8/20171 
H1241 1 
H12517/11/201733
H12617/12/20172 
H1271 1 
H12817/15/201711

 

Table 2

Product nameversiondateQuantity1Quantity2
H12317/7/201733
H1232 11
H12417/9/201711
H1251 33
H1261 22
H12717/14/201711
H12817/15/201711

 

I want to get the table after combine as below

Product nameversiondateQuantity1Quantity2
H12317/7/201733
H12327/8/201711
H12417/9/201711
H12517/11/201733
H12617/12/201722
H12717/14/201711
H12817/15/201711

 

 

How could I get that?

 

1 ACCEPTED SOLUTION
v-huizhn-msft
Microsoft Employee
Microsoft Employee

Hi @Henry1943,

1. I create a unique calculated column using the formulas. And create relationship between the two tables.

Column = Table1[Product name]&Table1[version]
Column = Table2[Product name]&Table2[version]


2. In table1, create calculated column using the formulas.

New Date = IF(ISBLANK(Table1[date]),RELATED(Table2[date]),Table1[date])
New Quantity2 = IF(ISBLANK(Table1[Quantity2]),RELATED(Table2[Quantity2]),Table1[Quantity2])


3. Create a new table by clicking "New Table" under Modeling on Home page.

Result = SELECTCOLUMNS(Table1,"Product name",Table1[Product name],"version",Table1[version],"date",Table1[New Date],"Quantity1",Table1[Quantity1],"Quantity2",Table1[New Quantity2])

Please see the expected result.

1.PNG

Please download the attached file to test.

Best Regards,
Angelia

View solution in original post

1 REPLY 1
v-huizhn-msft
Microsoft Employee
Microsoft Employee

Hi @Henry1943,

1. I create a unique calculated column using the formulas. And create relationship between the two tables.

Column = Table1[Product name]&Table1[version]
Column = Table2[Product name]&Table2[version]


2. In table1, create calculated column using the formulas.

New Date = IF(ISBLANK(Table1[date]),RELATED(Table2[date]),Table1[date])
New Quantity2 = IF(ISBLANK(Table1[Quantity2]),RELATED(Table2[Quantity2]),Table1[Quantity2])


3. Create a new table by clicking "New Table" under Modeling on Home page.

Result = SELECTCOLUMNS(Table1,"Product name",Table1[Product name],"version",Table1[version],"date",Table1[New Date],"Quantity1",Table1[Quantity1],"Quantity2",Table1[New Quantity2])

Please see the expected result.

1.PNG

Please download the attached file to test.

Best Regards,
Angelia

Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.

Top Solution Authors