group loop - transpose // how to get many rows in just one row?

Hello,

I want to use a group loop and then transpose each group to get just one row of data for each group.

If I just create a workflow like

Group Loop Start > Transpose > (optional: Filter >) Loop End. 

The Loop End gives an error: Execute failed: ("ArrayIndexOutOfBoundsException"): null

 

Maybe I should do an example, the data look like:

 

Group-ID | Var1 | Var2 | Var3

1               |  A1    |   B1   |   C1
1               |  A2    |   B2   |   C2
1               |  A3    |   B3   |   C3

2               |  A4    |   B4   |   C4
2               |  A5    |   B5   |   C5
2               |  A6    |   B6   |   C6

And I need an output like:

1               |  A1    |   A2   |   A3  |  B1    |   B2   |   B3  |  C1    |   C2   |   C3
2               |  A4    |   A5   |   A6  |  B4    |   B5   |   B6  |  C4    |   C5   |   C6

(there are 1 to 20 rows per Group-ID)

Besides this specific problem, I am somewhat confused by the Loop-Nodes in general. Is there a good reference to read about those?

Thank you
Tobias

This looks more like something for Pivoting... Are you sure group loop is required here?

You can do this with a groupby (list aggregation) and a java snippet (or a split collection column)

Hi, an other solution in the workflow in attachment.

Personally I would do a groupby on groupid and aggregate on the other columns using list as aggregation type.

then use split collection cell node on the List cells.

simon.

Thank you - I will try these approaches.