How to include file CSV Writer in a loop?

Total beginner to KNIME (esp. with looping/flow variables), so apologies for what’s probably a simple problem:

I’ve created a flow that begins with manually pointing file reader to get the input, does a bunch of simple data manipulation, then uses CSV writer at the very end to manually save the output.

I’ve started looking into loops so that this process will iterate for any number of files stored in a folder called ‘For Loop’. I think I have the start of it sorted out by using List Files > Table Row to Variable Loop Start, then using the URL flow variable to steer the File Reader that begins the original flow.

That’s fine and good, but I don’t know how to deal with the output side of it. For one, CSV writer has no output (I mean the black triangles you use to link nodes), so how can you include writing as part of a loop? That’s my first barrier, but I’m also wondering how you can store the current iteration’s file name to automatically have the file writing use a naming convention of [input name] & “_output”

Thanks for any guidance.

Hi @braunnz and welcome to the KNIME community forum,

You can find your answer here (and learn more about loops in KNIME):

And here you can learn more about making use of flow variables in KNIME:



Hi @braunnz

or take a look at this one from the KNIME hub with lots of other examples.
gr. Hans


Thanks for a great place to start!


The workflow you linked helped me get my loop working as intended, thanks a lot!


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