DEV Community

Cover image for #136 — Put Data in a Group Horizontally into Columns
Judith-Data-Processing-Hacks
Judith-Data-Processing-Hacks

Posted on

2 1 1 1 1

#136 — Put Data in a Group Horizontally into Columns

Problem description & analysis:

Here below is a data table:

source table
Task: Rank the students by score, and arrange the names with the same score into the same row. The result is as follows:

result table

Solution:

Use SPL XLL and enter the following code:

=spl("=E(?1).group(-Score).([#]|~.(Name))",Sheet1!A1:B25)
Enter fullscreen mode Exit fullscreen mode

Code explanation:

Group by Score and sort in reverse order; loop through each group, and merge the group number and the name of students in the group into a sequence.


Download esProc Desktop for FREE and level up your Excel skills now!! 🚀✨⬇️

✨SPL download address: esProc Desktop FREE Download

✨Plugin Installation Method: SPL XLL Installation and Configuration

✨References to other rich Excel operation cases: Desktop and Excel Data Processing Cases

✨YouTube FREE courses: SPL Programming

Image of Docusign

🛠️ Bring your solution into Docusign. Reach over 1.6M customers.

Docusign is now extensible. Overcome challenges with disconnected products and inaccessible data by bringing your solutions into Docusign and publishing to 1.6M customers in the App Center.

Learn more

Top comments (1)

Some comments may only be visible to logged-in visitors. Sign in to view all comments.

Sentry image

See why 4M developers consider Sentry, “not bad.”

Fixing code doesn’t have to be the worst part of your day. Learn how Sentry can help.

Learn more