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
To use this workflow in KNIME, download it from the below URL and open it in KNIME:
Download WorkflowDeploy, schedule, execute, and monitor your KNIME workflows locally, in the cloud or on-premises – with our brand new NodePit Runner.
Try NodePit Runner!Do you have feedback, questions, comments about NodePit, want to support this platform, or want your own nodes or workflows listed here as well? Do you think, the search results could be improved or something is missing? Then please get in touch! Alternatively, you can send us an email to mail@nodepit.com.
Please note that this is only about NodePit. We do not provide general support for KNIME — please use the KNIME forums instead.