Knime - how to keep key column in right outer join?

I have two tables, where I want to do a right outer join. In the second tab of the joiner configuration, I decide which columns I want to keep.

However, I have noticed that when I pick the column I joined on, it only appears in the result if I choose it from the first (left) table. If I choose it from the second table, it is ignored.

This is not a problem with an inner join, where it doesn’t matter if I pick the key column from the left or right table. But in a right outer join, if I pick the key from the left table, I am left with tons of missing values.

I know that I could do a left outer join, but 1) there are times when the right join makes more logical sense, and 2) maybe I am misunderstanding something and I am worried about making subtle mistakes. So, what would be the right way to do my right outer join while keeping the key column?


Example

Left table:
colors

Right table:
basic info

Settings:

Join result - here I want the “Person” column to appear too, but it’s missing:
output table

MWE joiner missing column.knwf (11.5 KB)

people.xlsx (8.7 KB)

Hi @rproynova,

welcome to the KNIME forum :slight_smile:

In the second tab of the configuration in the lower, right part you have the option to select between removing joining columns from bottom or top input table. Changing the default setting to remove joining column from top input table should solve you problem.

Best
Kathrin

4 Likes

Hello @rproynova,

I recommend you check out new, enhanced and faster, Joiner node - Joiner (Labs).

Br,
Ivan

2 Likes

Hi Kathrin,

thanks! I’m working on a smallish screen and didn’t notice I can scroll down the second configuration tab for more options. This is exactly what I needed.

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