5.10 Split by column - merge duplicate rows after splitting
There is a product data table ProductCategories.xls:
This table contains the category information of products, such as CategoryID, CategoryName, Description, etc. Now we need to separate the category information columns to form one Categories table, and take the remaining product columns as the Products table. Since there are many products under one category field, and many of them are duplicate after splitting, deduplication needs to be performed.
The results after splitting are shown as below:
Categories.xlsx:
Products.xlsx:
Script:
A | |
---|---|
1 | =T(“ProductCategories.xlsx”) |
2 | =A1.groups(CategoryID,CategoryName,Description) |
3 | =A1.new(CategoryID,ProductID,ProductName,QuantityPerUnit,UnitPrice,UnitsInStock,UnitsOnOrder,ReorderLevel) |
4 | =T(“Categories.xlsx”,A2) |
5 | =T(“Products.xlsx”,A3) |
esProc Desktop and Excel Processing
5.9 Split by column - by column - take column name as Sheet name
5.11 Split multi-Sheet file into multiple files - unfixed number of Sheets
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/