Questions on "Collection of String" Variable

Hi, I just found that the recent update changed a lot of nodes to accept “Collection of String” “S()” as flow variable to control in the loop or for the nodes.

I have quite a few questions as below:

  1. Is there any way to create the “Collection” other than [[Create Collection Column]]?
    **I guess the flow is like setting a table values in different columns (or by [[Cell Splitter]]), then use the [[Create Collection Column]] + [[Table row to Variable]]

  2. Although the aggregatedValues made by [[Create Collection Column]] can be handled by [[Table row to variable]], it seems to be ignored by the [[Table Row to Variable Loop Start]].

  3. Is there a way to convert multiple flow variable (String) into “Collection of String” to apply in nodes like those “Rule-based”, "Rule Engine’’ and “Filters”?

Thanks.

Best,
Cyrus

Hi there @cyrusl0822,

you are correct. This change happen with KNIME version 4.1.0. Let me try to answer your questions.

  1. Yes, multiple nodes can create Collection/List column as part of output. Some are Cell Splitter, GroupBy, Pivoting, Column Expressions

  2. Correct again! As you noticed this change has been introduced recently and not all nodes are adapted to support new flow variable types. Regarding Table Row To Variable Loop Start there is ticket (internal reference: AP-14041) for it and will add +1 there for you.

  3. If I got you right yes. Above mentioned Column Expressions can be used to create collection column using flow variables.

Hope this helps!

Edit: Add Java Snippet node to list in points 1 and 3…

Br,
Ivan

4 Likes

Thanks for letting me know!
Didn’t know about the column expressions before.
Definitely will try it out.
Thanks!

1 Like

Hi, what’s the status with AP-14041?

Hi @Gavin_Attard,

haven’t made it into new (4.2.0) release. Will give it +1.

Br,
Ivan

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