Can someone give me a better way to merge Excel files which contain similar sheets with similar names and columns but with different data File2.xlsx (10.3 KB) File2.xlsx (10.3 KB) File2.xlsx (10.3 KB)
I have attached sample files, i have to create a fourth file with all the data from the above files, sheets.
In a While loop (condition could be if there are files present in a source folder to process, moving processed files to another folder), Read each file into a datatable, then add each row to a Final Output datatable. Move the processed file to another folder.
Outside the loop then write the final datatable to Excel.
Thanks for the reply @Palaniyappan,
We tried it with MERGE DATATABLE activity but i wanted some other way rather than that
Please guide if you know thanks !!
Sure, slight variation on what I explained and it uses the MergeDatatable activity suggested elsewhere also. It looks to a specified folder of excel files, and merges them as longs as:
The files have the same column names as defined in the ‘Output Table’ excel file.
The sheet names are the same - in the example I merge only the “Key” sheets.
It produces a CSV output with a table of all merged data but can easily be adapted to write the data into the Output Table file.