Concatenate the same group of data into text
Example
There is an Excel file emp.xlsx, the data is as follows:
Group by DEPT and bring NAME together, the result is as follows:
Write SPL script:
A |
|
1 |
=T("e:/work/emp.xlsx") |
2 |
=A1.group(DEPT;~.(NAME).concat@c():NAME) |
3 |
=T("e:/work/emp2.xlsx",A2) |
A1 Read emp.xlsx file
A2 Group by DEPT, and concatenate the NAME sequence in the group with a comma to form a text named NAME field
A3 Save the result in A2 to the file emp2.xlsx
SPL Official Website 👉 http://www.scudata.com
SPL Feedback and Help 👉 https://www.reddit.com/r/esProc
SPL Learning Material 👉 http://c.scudata.com
SPL Source Code and Package 👉 https://github.com/SPLWare/esProc
Discord 👉 https://discord.gg/ydhVnFH9
Youtube 👉 https://www.youtube.com/@esProc_SPL