Skip to content
KNIME Documentation
Main Navigation Get startedBuildWork with KnimeAccount and adminRelease notesDeveloper tools
Community Hub
DevelopersKnime 2.0
Sidebar Navigation

Getting Started

Installation

User Guide

Release Notes

Install Extensions

Building Workflows

Components

Flow Control

Expressions

File Handling

Deployment

Integrated Deployment

Workflow Invocation

Best Practices

Advanced Features

AI Extension

Get Started

Build an Agent

Inject context with RAG

LLM Providers

Tutorials

Summarize product reviews

Product FAQ assistant

Restaurant agent

Your first local agent

Task extractor

Reporting

Kerberos

Extensions

Database

Overview

Tutorials

Read and filter data from a database

Write a transformed dataset to a database

Concepts

Ports and Sessions

Query Generation

Type Mapping

Deprecated Framework

Connecting

Connect: Dedicated Node

Connect: File-Based Database

Connect: Generic DB Connector

Register a JDBC Driver

Install Third-Party Driver Plug-in

Drivers on Hub and Server

Kerberos Constrained Delegation

Reading and Transforming

Read Data

Transform Data Visually

Run a Custom SQL Query

Parameterize a Query

Writing and Modifying

Insert, Update, or Merge

Delete Rows

Bulk Load Data

Create and Remove Tables

Use Transactions

Reference

Connector Node Settings

JDBC Driver Reference

Deprecated Node Mapping

Migrate Deprecated Workflows

Python

Overview

Tutorials

Python Scripting Quickstart

Data App Development Using Plotly

Data Processing

K-AI Scripting Assistant

Data Type Conversion

Batch Processing

Jupyter Integration

Environment Management

Pixi Configuration

Dependency Management

Environment Persistence

Channel Mirrors & Air-Gapped Setups

Conda Migration

Alternative Configurations

Conda and Miniforge Setup

Conda Environment Propagation

Manual Python Configuration

Legacy Node Migration

Concepts

Pixi Backend Architecture

Storage Logic

Python Environments on Executors

Reference

Python Scripting API

Bundled Packages

Executor and Hub Configuration

Troubleshooting Guide

API Reference

Inputs and outputs

Classes

Views

Utility functions

R

Deep Learning

Snowflake

Google Cloud

Azure

AWS

Big Data

Big Data Admin

Big Data Secured Cluster

Databricks

Microsoft Fabric

Power BI

Tableau

Report Designer

H2O

Changelogs

Version 5.12

Version 5.11

Version 5.10

Version 5.9

Version 5.8

Version 5.7

Version 5.6

Version 5.5

Version 5.3

Extensions

Use database transactions ​

Use the DB Transaction Start and DB Transaction End nodes to group multiple database operations into a single unit of work. Either all operations in the transaction succeed (commit), or none of them take effect (rollback).

Before you begin ​

  • Establish a database connection. See Connect to a database using a dedicated connector node.

Set up a transaction ​

Chain the transaction nodes around the database operations you want to group into a single unit of work.

  1. Connect the DB Connection output port to a DB Transaction Start node and execute it. This opens a transaction on the connection. The input connection cannot be used outside the transaction while it is open.
  2. Connect the DB Data or DB Connection output of DB Transaction Start to the first node in your transaction chain (for example, a DB Writer).
  3. Chain the database operation nodes in sequence.
  4. Connect the final node's output port to the first input port of a DB Transaction End node.
  5. Connect the DB Connection output of DB Transaction Start directly to the second input port of DB Transaction End.
  6. Execute the DB Transaction End node:
    • If all nodes in the chain executed successfully, the node commits the transaction and makes all changes visible.
    • If any node in the chain failed, the node rolls back the transaction and restores the database to its state at the start of the transaction.

TIP

The first input port of DB Transaction End should be connected from the end of the transaction chain. The second input port should be connected directly from DB Transaction Start. On commit, the first port's connection is forwarded to the output; on rollback, the second port's connection is forwarded.

Next steps ​

  • Insert, update, or merge data
  • Delete rows from a database table

Related pages ​

  • DB ports and sessions
  • Create and remove database tables
Pager
Next pageInstallation