Forum Discussion
Merge / append two columns from 2 tables
Hi all
I have seen various iterations of this topic on the forums but none meet my sepcific requirement. I have two tables:
Table A
| Name | SerialNumber |
| Hostname1 | PC0TKV9P |
| Hostname2 | MJ06T78T |
| Hostname3 | S4L43403 |
Table B
| Device name | OS | OS version | Manufacturer | Serial number |
| Hostname11 | Windows | 10.0.19045.2846 | SAMSUNG ELECTRONICS CO., LTD. | ZQ4W93AZ300561 |
| Hostname12 | Windows | 10.0.19044.2846 | LENOVO | YM101ZF9 |
| Hostname13 | Windows | 10.0.19044.2846 | LENOVO | YH011NVM |
What I would like is to create a new table with two columns, one for Name and one for Serial number, e.g.:
Table C
| Name | SerialNumber |
| Hostname1 | PC0TKV9P |
| Hostname2 | MJ06T78T |
| Hostname3 | S4L43403 |
| Hostname11 | ZQ4W93AZ300561 |
| Hostname12 | YM101ZF9 |
| Hostname13 | YH011NVM |
Any help / suggestions would be greatly appreciated!
algorton In your Power Query Editor, edit the query for your 2nd table and remove your OS Version and Manufacturer columns. Then Append the queries.
Hi,
Only change the column names in Power Query before the Append. In the table B, instead of 'Device name', switch it to 'Name' (as in the table A) and 'Serial Number' to 'SerialNumber'.
Once Appended, you can keep only these two columns.
4 Replies
- grodriguezbRegular Visitor
Hi,
Only change the column names in Power Query before the Append. In the table B, instead of 'Device name', switch it to 'Name' (as in the table A) and 'Serial Number' to 'SerialNumber'.
Once Appended, you can keep only these two columns.
- Greg_DecklerCommunity Champion
algorton In your Power Query Editor, edit the query for your 2nd table and remove your OS Version and Manufacturer columns. Then Append the queries.
- algortonFrequent Visitor
Hi Greg
Thanks for the suggestion, I need the information in table b for other parts of the report; do you think if I copy the table and then perform the optiosn you suggested is the best way to approach this?
- algortonFrequent Visitor
Greg_Deckler grodriguezb Thank you both; using both these suggestions I am now up and running!
I appreciate your quick responses!