5.9 Split by column - by column - take column name as Sheet name

 

There is a file Amount.xlsx as shown below:

imagepng

This is an amount summary table for certain products purchased by some key customers. Now we need to split it by product, and save each product to a Sheet with the product name as the Sheet name and Amount as the column name. The split results are as follows:

imagepng

imagepng

imagepng

Script:

A B
1 =T(“Amount.xlsx”) =A1.fname()"Name"
2 for B1 =A1.new(Name,${A2}:Amount)
3 =file(“Amounts.xlsx”).xlsexport@ta(B2;A2)

esProc Desktop and Excel Processing
5.8 Split by column - by column - take column name as file name
5.10 Split by column - merge duplicate rows after splitting