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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
stranter
Frequent Visitor

Merge 2 columns from 2 different tables with different structures

Hi,

 

I'm not sure where to begin with what I want to do.  I have two tables, of differing structures, but with one column which is the same.  I want to combine this column in a seperate table and remove the duplicates:

 

Capture.PNG

 

I'm not sure where to begin so any suggestions are welcome!

 

Thanks,

 

Stewart

2 ACCEPTED SOLUTIONS
ryan_mayu
Super User
Super User

@stranter

 

Maybe you can try this code. Thanks.

 

Table = 
VAR regis=values(Table1[ID])
VAR app=VALUES(Table2[ID])
return DISTINCT(UNION(regis,app))

 

 




Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




View solution in original post

v-yuta-msft
Community Support
Community Support

@stranter,

 

Power Query can also achieve your requirement, please refer to steps below:

 

1. Click query editor-> Merge as new-> select Full Outer.

Capture.PNG  

 

2. Expand by ID column of application and remove the useless column.

1.PNG 

 

3. The result will be like below:

2.PNG 

 

Community Support Team _ Jimmy Tao

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

2 REPLIES 2
v-yuta-msft
Community Support
Community Support

@stranter,

 

Power Query can also achieve your requirement, please refer to steps below:

 

1. Click query editor-> Merge as new-> select Full Outer.

Capture.PNG  

 

2. Expand by ID column of application and remove the useless column.

1.PNG 

 

3. The result will be like below:

2.PNG 

 

Community Support Team _ Jimmy Tao

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

 

ryan_mayu
Super User
Super User

@stranter

 

Maybe you can try this code. Thanks.

 

Table = 
VAR regis=values(Table1[ID])
VAR app=VALUES(Table2[ID])
return DISTINCT(UNION(regis,app))

 

 




Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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