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

Try your skills in the Power BI Dataviz World Championship! Round one ends June 26. Join now

Reply
thassan77
Frequent Visitor

Append multiple sheet in the same excel File

Ok guys, help me out. I have one excel file with multiple tab (sheet) in it. All I want to create another excel file using power query and merge the data into one large file in a different location. So in future i can create more tabs/sheet in the source file and the output file will be updated when refresh. Basically all i want get data from a single excel file which has multiple tabs and transform it into one large data into a separate file.

 

Appreciate your help.

1 ACCEPTED SOLUTION
lbendlin
Super User
Super User

This can be done easily with a slight modification of the Power Query code.

 

Connect to the Excel file as usual. Pick one sheet, and say "Transform data"

Then remove the second step, and expand all sheets instead.

 

let
    Source = Excel.Workbook(File.Contents("C:\Users\xxx\test5.xlsx"), null, true),
    #"Expanded Data" = Table.ExpandTableColumn(Source, "Data", {"Column1", "Column2"}, {"Column1", "Column2"})
in
    #"Expanded Data"

 

After that do some cleanup on the sheet headers as needed.

View solution in original post

1 REPLY 1
lbendlin
Super User
Super User

This can be done easily with a slight modification of the Power Query code.

 

Connect to the Excel file as usual. Pick one sheet, and say "Transform data"

Then remove the second step, and expand all sheets instead.

 

let
    Source = Excel.Workbook(File.Contents("C:\Users\xxx\test5.xlsx"), null, true),
    #"Expanded Data" = Table.ExpandTableColumn(Source, "Data", {"Column1", "Column2"}, {"Column1", "Column2"})
in
    #"Expanded Data"

 

After that do some cleanup on the sheet headers as needed.

Helpful resources

Announcements
Fabric Data Days is here Carousel

Data Days 2026

Don't miss out on Data Days, June 15 through August 7. Learn Fabric, Power BI, SQL, AI and more.

May Power BI Update Carousel

Power BI Monthly Update - May 2026

Check out the May 2026 Power BI update to learn about new features.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.