Question Workflow "Compare Two Tables"

Hi Everyone,
I am using the workflow “Compare Two Tables”. I have 50 columns, but when the flow compares the columns, it compares “column 1” not only to “column 1” but also to column 11, 12, 13 etc.
How can I change this in the workflow so it only compares two the same columns (so only column 1 with column 1, and column 11 to column 11)?
Any help is much appreciated, thanks!

Hi @Stephanie_BOLD

I think you have 2 options:

  1. Modify the way the workflow creates the “ColumnNamesWildCard” variable so that it works in your context. The original workflow only had 3 columns, so using the wildcard “column1*” only matched “column1” and “column1 (#1)” for the comparison. Since you have more columns with 1’s in them it doesn’t work.

  2. Use better (i.e. more descriptive and unique) column names.

1 Like

Hi there @Stephanie_BOLD,

welcome to KNIME Community!

If not mistaken that is my workflow! Probably I should have done proper testing with more than 3 columns included :smiley:

Anyways here is modified workflow that should work (will test more tomorrow and upload new version on Hub). Instead of using wildcard I used collection flow variable to control columns left after Column Filter node.
2019_10_03_Comparing_Two_Tables_new.knwf (43.1 KB)

Note: Actually comparison was ok only Column Filter left more columns than it should :wink:

Br,
Ivan

4 Likes

Hi @ipazin,

Thank you so much for uploading a modified workflow! This is really helpful :D!

Best, Stephanie

1 Like

Thanks for your help @elsamuel!

Hi @Stephanie_BOLD,

glad it helped!

Workflow is updated and available on KNIME Hub here:

Br,
Ivan

3 Likes

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