March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early bird discount ends December 31.
Register NowBe one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now
Hi Everyone,
There is one question, Can we combines files with differnt structure in Powerquery. Example : one excel file contain column A, B, C, D but second file contains A, B, C, D, E
Can we combine those files and get the result in one table like A, B, C, D, E
Please let me know if there is any solution to get the above solution.
Thanks,
Lisha
Solved! Go to Solution.
Hi @lishapruthi ,
Replace the expanded column names with the following code:
List.Distinct(List.Combine(List.Transform (#"Removed Other Columns1"[Transform File],each Table.ColumnNames(_))))
Best Regards,
Gao
Community Support Team
If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!
How to get your questions answered quickly -- How to provide sample data in the Power BI Forum -- China Power BI User Group
Hi Lisha,
You can put them in a folder.
Here use Combine & Transform data --> Ok.
An automated query is executed here:
Check the table under Other Queries --> Go to this query --> Manually expand and remove the following extra steps
Output:
Best Regards,
Gao
Community Support Team
If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!
How to get your questions answered quickly -- How to provide sample data in the Power BI Forum -- China Power BI User Group
Hi @v-cgao-msft ,
But is there any solution to get columns dynamically because everytime new file added in the folder there willl be more columns than previous files. In that case, we cannot update in powerquery everytime. it should be added automatically.How can we solve this issue.
Thanks,
Lisha
Hi @lishapruthi ,
Replace the expanded column names with the following code:
List.Distinct(List.Combine(List.Transform (#"Removed Other Columns1"[Transform File],each Table.ColumnNames(_))))
Best Regards,
Gao
Community Support Team
If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!
How to get your questions answered quickly -- How to provide sample data in the Power BI Forum -- China Power BI User Group
Hi @lishapruthi,
Using merge queries to join the two tables into a single table. but there are similar columns needed to make a join between the two tables.
Did I answer your question?
Mark my post as a solution, this will help others...!
Hit the kudo also,
Thank you.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.
User | Count |
---|---|
125 | |
85 | |
69 | |
54 | |
45 |
User | Count |
---|---|
204 | |
106 | |
98 | |
65 | |
54 |