0 ×

DB Update

StreamableKNIME database nodes version 4.1.0.v201911301831 by KNIME AG, Zurich, Switzerland

Updates all data rows from the selected database table that match the values of a row from the selected KNIME input table columns. All selected column names of the KNIME table need to exactly match the column names from the database. The WHERE column values of the input KNIME data row need to match the values of the database row to update; whereas the SET database column values are replaced by the input KNIME column values. Only the rows matching all values of the selected column of any given input row will be updated. The column order of the KNIME table and the database table do not need to match.
The output table contains two additional columns if Append update statuses checkbox is checked. The first extra columns is the number of rows affected by the UPDATE statement. A number greater than or equal to zero -- indicates that the command was processed successfully and is an update count giving the number of rows in the database that were affected by the command's execution. A value of -2 -- indicates that the command was processed successfully but that the number of rows affected is unknown. The second shows a warning message, if any.

Options

Settings

Table to udpate
Click Select a table to select the table to update in the pop up dialog, or enter a valid Schema and Table name into the input fields.
Batch size
Enter a number greater than 0 for the number of rows updated in one batch job. Entering 1 disables batch processing. This way only one row is processed at a time.
Fail on error
Disable this if you want to continue after an error.
Append update status columns
Enable this to append two additional (status and error) columns to the output table .
Disable DB Data output port
Select this option to disable the DB Data output port and the execution of the metadata query at the end of the node execution which might cause problems with databases that do not support subqueries.
Select the columns to update (SET in SQL)
Select the columns which should be updated in the database. The column names in the KNIME input table need to match the column names in corresponding database table. In SQL this is equivalent to the SET columns.
Select identification columns (WHERE in SQL)
Select all columns used to identify the records in the database that should be updated. Only records in the database that match the values from the input table are updated. The column names in the KNIME input table need to match the column names in corresponding database table. In SQL this is equivalent to the WHERE columns.

Output Type Mapping

This tab allows you to define rules to map from KNIME types to database types.

Mapping by Name
Columns that match the given name (or regular expression) and KNIME type will be mapped to the specified database type.
Mapping by Type
Columns that match the given KNIME type will be mapped to the specified database type.

Input Ports

KNIME data table with the data rows to be updated in the database.
DB Connection to the database.

Output Ports

Input KNIME data table with additional columns providing the number of affected rows in the database and warnings, if checked in the dialog.
DB Data referencing the selected database table.

Best Friends (Incoming)

Best Friends (Outgoing)

Workflows

Installation

To use this node in KNIME, install KNIME Database from the following update site:

KNIME 4.1

A zipped version of the software site can be downloaded here. Read our FAQs to get instructions about how to install nodes from a zipped update site.

Wait a sec! You want to explore and install nodes even faster? We highly recommend our NodePit for KNIME extension for your KNIME Analytics Platform.

Developers

You want to see the source code for this node? Click the following button and we’ll use our super-powers to find it for you.