Workflow demonstrating some ways to perform a join where part of the join condition is not based on perfect equality. The Joiner node can only join using "equal", so the joiner can be used to perform the part of the join it can produce, and then other standard nodes can be used together to filter those rows that match the remainder of the condition, in a similar way to a Rule Based Row Filter would work. In some cases a Rule Based Row Filter could be used here, but where calculations are required, the Rule nodes are not capable of the required matching, so String Manipulation or Math Formula nodes can be utlised instead.
Another option is to use Math Formula to provide the lower and upper range boundaries for one of the values and then use a Rule-Based Row Filter to keep only those rows where the other Value is within that range
Alternatively, a custom component can be used to provide a "custom condition" utilising a SQL condition compatible with the H2 database
https://hub.knime.com/takbb/spaces/Public/latest/Components/Joiner%20Components/Join%20Custom%20Condition%20-%20indexed
And a further possibility, for greater flexibility and allowing the query to be written using DB Query nodes, components can be used for creating copies of the data in an H2 database:
https://hub.knime.com/takbb/spaces/Public/latest/Components/Joiner%20Components/KNIME%20Table%20Session%20Connector
and
https://hub.knime.com/takbb/spaces/Public/latest/Components/Joiner%20Components/KNIME%20Table%20Connector
Workflow
Demo Options for matching based on non-equal values
External resources
Used extensions & nodes
Created with KNIME Analytics Platform version 4.7.4
- Go to item
NoOp Nodes
This is an unpublished or unknown extension.
Philipp Katz; nodepit.com
Version 1.0.1
Legal
By using or downloading the workflow, you agree to our terms and conditions.