Forum Discussion
How do I copy columns from multiple sheets into a new sheet?
Hello,
I'm trying to figure out how to do something that seems relatively simple, but I can't figure it out. I have two Excel sheets that contain my source data, and I'd like to use Power BI to copy a couple columns from each of the sheets into a new table in which I can perform manipulations.
Here are examples of my source tables:
Source Table 1
Source Table 2
Output Table:
Copy columns 1-2 in table 1 and columns A-B in table 2 into output table.
The goal is to make it so that whenever updates are made to the source sheet, all I have to do is refresh Power BI to see my changes reflected in the new table.
Thanks in advance for your help!!
- Anonymous6 years ago
Anonymous - Is there any relationship between the 2 sheets? If it's simply mapping the same row on each sheet, you could do the following in Power Query:
- Import both tables
- Add an Index column to both tables
- Merge one table into the other, joining on the Index columns.
- Expand columns.
- Remove any unnecessary columns
I hope this helps. If it does, please Mark as a solution.
I also appreciate Kudos.
2 Replies
- AnonymousNot applicable
Anonymous - Is there any relationship between the 2 sheets? If it's simply mapping the same row on each sheet, you could do the following in Power Query:
- Import both tables
- Add an Index column to both tables
- Merge one table into the other, joining on the Index columns.
- Expand columns.
- Remove any unnecessary columns
I hope this helps. If it does, please Mark as a solution.
I also appreciate Kudos.- AnonymousNot applicable
Thanks a ton, worked like a charm!