How to incorporate data elements from several KNIME tables into a single Excel sheet

Hi @Cosmo72 ,

If your tables are all KNIME data tables from different parts of your workflow, then I don’t really see any way of accessing these via a loop.

On the face of it, a series of Joiner nodes should be all you need, but I agree that doesn’t scale well for a large number of tables being joined, in terms of the growing number of nodes required.

However, I’m also not sure why an empty table is causing your joins to break. Can you give an example of how that happens?

In this mockup, I’m representing tables that have been created in your workflow using CSV Readers, but let’s imagine that these are just a set of data tables from elsewhere in your workflow.

Even though Table B (Table 2) is empty, the workflow completes and generates the following:


The exclamation marks on the branch from TableB(2) are advisory warnings and don’t stop the workflow from completing.


If instead of individual tables in your workflow, you output the different tables from parts of your workflow into files (e.g. numbered CSV files), then I could see more potential for some kind of loop construct.

You could have a counting loop which causes numbered CSV (or other) files to be read in turn from a single folder, and joined to the main table. The results would be collected and the output at the end.

In the case where a CSV is actually missing (if that could occur), rather than just empty , a try-catch could be used to replace the missing file with an empty table, which again would function perfectly well.

Some additional work was required within the loop here to ensure rows were collected in the same order through each iteration, to avoid a misalignment of rows when the columns were combined on exiting the loop. There are possibly other (better) approaches that could be taken here, but time was short and it kind of worked so hopefully it gives some ideas. :wink:

Combining multiple sheets 1.knwf (149.1 KB)

4 Likes