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

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

Reply
Anonymous
Not applicable

Combining 2 tables without matching rows

Hello, is it possible to combine 2 tables some column match but some aren't match without any matching rows. Just wanted to make this 2 dataset saved as 1 table?

 

Here's the column for my 1st data set

xRTP_0-1668181657883.png

 

Here's the column for my 2nd data set

xRTP_1-1668181731414.png

 

For the columns that are matching the data would just append and the other columns that arent present on the 1st table will beadded. Thanks in advance

 

1 ACCEPTED SOLUTION
v-yadongf-msft
Community Support
Community Support

Hi @Anonymous ,

 

Table1:

vyadongfmsft_0-1668500446976.png

 

Table2:

vyadongfmsft_1-1668500476748.png

 

Please try following measure to create a new table to combine two tables:

Table = UNION(
    SELECTCOLUMNS('Table1',"Column1",'Table1'[Column1],"Column2",'Table1'[Column2]),
    SELECTCOLUMNS('Table2',"Column1",'Table2'[Column1],"Column2",'Table2'[Column2])
)

 

Is this the result you want?

vyadongfmsft_2-1668500574940.png

 

Best regards,

Yadong Fang

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

6 REPLIES 6
v-yadongf-msft
Community Support
Community Support

Hi @Anonymous ,

 

Table1:

vyadongfmsft_0-1668500446976.png

 

Table2:

vyadongfmsft_1-1668500476748.png

 

Please try following measure to create a new table to combine two tables:

Table = UNION(
    SELECTCOLUMNS('Table1',"Column1",'Table1'[Column1],"Column2",'Table1'[Column2]),
    SELECTCOLUMNS('Table2',"Column1",'Table2'[Column1],"Column2",'Table2'[Column2])
)

 

Is this the result you want?

vyadongfmsft_2-1668500574940.png

 

Best regards,

Yadong Fang

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Anonymous
Not applicable

Hello, tried this and works like magic! Thanks a lot!!

mangaus1111
Solution Sage
Solution Sage

Hi @Anonymous ,

you can try maybe with

DISTINCT(UNION(Table1,Table2))

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Anonymous
Not applicable

Do i need to create a new table that consist all of the columns then use union all? Actually I have total of 3 table, 1 for mapping and 2 for may dataset. Im thinking to create 1 more table > use union all > created union table to make a relationship with my mapping table? Is it possible?

 

djurecicK2
Super User
Super User

Hi @Anonymous ,

 You can create a calaculted column in the table 1 and use LOOKUPVALUE

https://learn.microsoft.com/en-us/dax/lookupvalue-function-dax

 

to get values from the first column of table 2

Anonymous
Not applicable

Lookupvalue cant get duplicates, im having duplicate on column "employeeName" since the data was entered per month. Is there any other solution? Im getting this error because of duplicate "A table of multiple values was supplied where a single value was expected."

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 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.