Filling multiple columns

Dear all,

I have a table with following columns:
key
count
a H001
b H001
a H002
b H002

a H010
b H010

Depending on the value from column count I have to copy the value from a H001 and aH002 to the other columns; e.g. when
count = 2: I have to fill the fields a H002, b H002 with a H001, b H001
count = 3: I have to fill the fields a H002, b H002, a H003, b H003 with a H001, b H001
count = 4: I have to fill the fields a H002, b H002, a H003, b H003, a H004, b H004 with a H001, b H001

In VBA I would realize this with a for next construct; in knime I found the only way doing it with java snippet.

Is there a smarter way (in real i have a H001, b H001, c H001, d H001, e H001, f H001, g H001, h H001 to a H020, b H020, c H020, d H020, e H020, f H020, g H020, h H020

Attached you can find input and wanted input result.

Thanks for help!

BR,

Heinz
test 6 to Knime from HS.knwf (19.0 KB)

Hi Heinz,

I have the feeling that you want to work with KNIME exactly like you do in Excel. E.g. you set cell by cell each value in your table. This can be done, but is not very efficient in the data handling.
Here’s the solution I created for you:

Can you say something about aim you have? What plots or kind of data analysis do you want to do with your final dataset? Maybe we can take some shortcuts to get data in a proper format

1 Like

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