Write subtables out of table

Does anyone have an idea how I can loop over an excel table and write subtables out of the main table?

In the main table I have multiple columns and one column containing a category.
I want to groupby the category and create subtables for every category.

What I have done is using a GroupBy on the category column and then use the Table Row to Variable Loop Start in which I use a Rule based Row Filter to create subtables for each category.

But there is no Node to create tables where I can and the loop afterwards… or is there?

Hi @MarStu,

what do you mean with subtables? Do you want create for each category a new excel sheet?

BR

Hi @morpheus,

exactly.
For each category, create a new excel sheet, or better; a completely new excel table (xls/xlsx file).

Hi @MarStu,

You can use the excel sheet appender to create a new file containing your individual category as a sheet. The only thing you need to do control your sheet names with your category workflow variable.

BR

Hi @morpheus,

and how do I close the loop after the Excel Sheet Appender?

You can use the variable loop end node.

Not after the Excel Sheet Apeender Node… it doesnt have a output Notescrnsht

use the correct loop end node!

Example

2 Likes

thank you so much!

Now it works.

1 Like

Hello @MarStu,

a bit more regarding correct loop nodes - there is Group Loop Start node which can be used to loop over different categories :wink:

Br,
Ivan

2 Likes

Hi @ipazin,
but nevertheless you have to define a variable with the category. So i think first use a group by node and then a tablerow to variable loops start would be the smarter option.

BR

No. The group loop start node can also handle the variable with the current value.

Luca

1 Like

Helllo!

As @Luca_Italy said Group Loop Start node outputs flow variable groupIdentifier (concatenation of all grouping columns) together with flow variable for each grouping column holding current value.

Br,
Ivan

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.