4.21 Aggregate files - same rows and columns
In practical business, sometimes we need to aggregate the data while merging multiple Excel files, for example:
Apple.xlsx
Bread.xlsx
Pork.xlsx
Now we need to aggregate the Amount fields to form a column “total” amount , and store it to a new file. The result is as follows:
Script:
A | |
---|---|
1 | =file(“Apple.xlsx”).xlsimport@t() |
2 | =file(“Bread.xlsx”).xlsimport@t() |
3 | =file(“Pork.xlsx”).xlsimport@t() |
4 | =A1.new(Name,Amount+A2(#).Amount+A3(#).Amount:TotalAmount) |
5 | =file(“TotalAmount.xlsx”).xlsexport@t(A4) |
esProc Desktop and Excel Processing
4.20 Format conversion - merge multiple primary-sub table files to form two row-based tables
4.22 Aggregate files - merge by row and column simultaneously - aggregate duplicate records
SPL Official Website 👉 https://www.scudata.com
SPL Feedback and Help 👉 https://www.reddit.com/r/esProc_Desktop/
SPL Learning Material 👉 https://c.scudata.com
Discord 👉 https://discord.gg/cFTcUNs7
Youtube 👉 https://www.youtube.com/@esProcDesktop
Linkedin Group 👉 https://www.linkedin.com/groups/14419406/