DuckDB inside OLTP databases
Report gate-sf10: scale factor 10, measured 2026-10-28 12:45 to 2026-10-29 07:16 UTC (18 h 30 min). Only this campaign's records are shown. All results

DuckDB inside OLTP databases

A neutral comparison of database servers that embed DuckDB, against plain DuckDB at several versions and row-store baselines, on the same TPC-H data with the same container limits. There is no overall score and no ranking: read each measure with its failures and its n/a cells.

Marks on charts and tables: ✗ wrong result (never drawn as a bar), T/O timeout, E error, C crashed, ! failed to run, – n/a. Hover a mark for the reason.

Findings

Computed from the result records of this page, one sentence per measure, with every system in the same order. They state counts and ranges; they do not rank systems or give an overall verdict. Each finding links to the measure's charts.

Correct answers

12 of 12 systems answered all 22 queries with the reference result.

Query time

On the 22 queries every integration answered correctly, the total warm time was 5.30 s to 151 s across all 5 integrations, and 2.96 s to 4.07 s for plain DuckDB.

  • AliSQL: 5.30 s
  • MariaDB: 5.49 s
  • Percona: 5.47 s
  • pg_duckdb: 151 s
  • pg_ducklake: 7.73 s
  • DuckDB 1.4.3: 4.07 s
  • DuckDB 1.5.2-dev736: 3.91 s
  • DuckDB 1.5.3: 3.90 s
  • DuckDB 1.5.5: 3.87 s
  • DuckDB 2.0.0: 2.96 s
  • MySQL InnoDB: 1,036 s
  • PostgreSQL: 188 s

Integration overhead

Against plain DuckDB at the same DuckDB version, the geometric-mean time ratio was 1.23x to 29.39x across all 5 integrations. 1x means no cost for running inside the server.

  • AliSQL: 1.23x against DuckDB 1.5.2-dev736
  • MariaDB: 1.28x against DuckDB 1.5.5
  • Percona: 1.64x against DuckDB 2.0.0
  • pg_duckdb: 29.39x against DuckDB 1.4.3
  • pg_ducklake: 2.04x against DuckDB 1.5.3

Concurrency

At 16 concurrent streams, throughput was 1,287 qph to 33,975 qph across all 8 systems measured.

  • AliSQL: 17,407 qph
  • MariaDB: 16,861 qph
  • Percona: 19,594 qph
  • pg_duckdb: 1,287 qph
  • pg_ducklake: 11,521 qph
  • DuckDB 1.4.3: 22,476 qph
  • DuckDB 1.5.5: 23,449 qph
  • DuckDB 2.0.0: 33,975 qph
  • pg_duckdb, 32 streams: 69 of 704 queries did not complete

SQL compatibility

120 SQL statements an OLTP application would send, checked against the server's own row-store tables. A wrong result is silent: the statement succeeds and the answer differs.

  • AliSQL: 15 errors, 2 wrong results, 0 n/a
  • MariaDB: 10 errors, 4 wrong results, 3 n/a
  • Percona: 0 errors, 0 wrong results, 0 n/a
  • pg_duckdb: 0 errors, 0 wrong results, 7 n/a
  • pg_ducklake: 15 errors, 2 wrong results, 0 n/a
  • Wrong result, AliSQL: Generated primary key values for rows inserted without an id (dml_auto_increment)
  • Wrong result, AliSQL: Insert-or-update on a primary key conflict (dml_upsert)
  • Wrong result, MariaDB: Insert-or-update on a primary key conflict (dml_upsert)
  • Wrong result, MariaDB: String concatenation, NULL propagates (fn_concat)
  • Wrong result, MariaDB: EXISTS across the two (engine table with a row-store table) (join_mixed_exists)
  • Wrong result, MariaDB: The session time zone (UTC+2) decides how a timestamp converts to epoch seconds (var_session_time_zone)
  • Wrong result, pg_ducklake: TRUNCATE TABLE, then insert one row and count (ddl_truncate)
  • Wrong result, pg_ducklake: The session time zone (UTC+2) decides how a timestamp converts to epoch seconds (var_session_time_zone)

Silent slow paths

TPC-H queries seen on the row path: none on 5 of the 5 integrations that report it. Of the read probes, the share answered on the row path instead of in DuckDB was 0% to 86.7%.

  • AliSQL: TPC-H 0%, probes 0%
  • MariaDB: TPC-H 0%, probes 4.9%
  • Percona: TPC-H 0%, probes 86.7%
  • pg_duckdb: TPC-H 0%, probes 10.6%
  • pg_ducklake: TPC-H 0%, probes 0%

Loading

Bulk load of the TPC-H data took 17.28 s to 1,523 s across all 10 systems.

  • AliSQL: 613 s
  • MariaDB: 761 s
  • Percona: 183 s
  • pg_duckdb: 1,095 s
  • pg_ducklake: 17.28 s
  • DuckDB 1.4.3: 184 s
  • DuckDB 1.5.5: 195 s
  • DuckDB 2.0.0: 137 s
  • MySQL InnoDB: 1,523 s
  • PostgreSQL: 1,074 s

Parquet entry points

4 of 4 systems answered all 22 queries with the reference result. On the 22 queries every entry point answered correctly, the total warm time was 7.39 s to 8.90 s across all 3 entry points, and 7.42 s for plain DuckDB.

  • MariaDB (run_in_duckdb): 8.65 s
  • pg_duckdb (duckdb.query): 8.90 s
  • VillageSQL: 7.39 s
  • DuckDB 1.5.5: 7.42 s

Headlines: tables stored in the database

Systems appear in the same order everywhere: database integrations A to Z, plain DuckDB, row-store baselines. Totals use only the queries every integration completed correctly, so everyone is scored on the same work. VillageSQL has no DuckDB table type, so its row here is n/a; its numbers are under Parquet entry points below.

Total query time, common queries (s)

Sum of warm medians over the queries that every integration ran correctly. Lower is better.

Throughput at 16 streams (queries per hour)

Concurrent TPC-H streams, warm cache. Higher is better.

Integration overhead vs plain DuckDB (geomean, common queries)

Ratio to plain DuckDB at the same version; the headline uses the same queries for every system. Each system's own geomean and its coverage are in the table below.

Headline numbers (SF10)

SystemDuckDBTotal, common queriesOwn total (ok/total) Throughput, 16 streams (qph)Overhead, commonOverhead, own geomean (ok/total)Plain baseline used
AliSQL 1.5.2-dev736 5.30 s 5.30 s (22/22) 17,407 1.23x 1.23x (22/22)
MariaDB 1.5.5 5.49 s 5.49 s (22/22) 16,861 1.28x 1.28x (22/22)
Percona 2.0.0 5.47 s 5.47 s (22/22) 19,594 1.64x 1.64x (22/22)
pg_duckdb 1.4.3 151 s 151 s (22/22) 1,287 29.39x 29.39x (22/22)
pg_ducklake 1.5.3 7.73 s 7.73 s (22/22) 11,521 2.04x 2.04x (22/22)
DuckDB 1.4.3 v1.4.3 4.07 s 4.07 s (22/22) 22,476 –
DuckDB 1.5.2-dev736 v1.5.2-dev736 3.91 s 3.91 s (22/22) – –
DuckDB 1.5.3 v1.5.3 3.90 s 3.90 s (22/22) – –
DuckDB 1.5.5 v1.5.5 3.87 s 3.87 s (22/22) 23,449 –
DuckDB 2.0.0 v2.0.0 2.96 s 2.96 s (22/22) 33,975 –
MySQL InnoDB n/a 1,036 s 1,036 s (22/22) – –
PostgreSQL n/a 188 s 188 s (22/22) – –
VillageSQL 1.5.5 – – – measured on Parquet files only; see Parquet entry points

Parquet entry points

A second workload on the same TPC-H data: DuckDB SQL over Parquet files, sent through each system's raw DuckDB entry point (VillageSQL duckdb_query(), pg_duckdb duckdb.query(), MariaDB run_in_duckdb()) and plain DuckDB. These numbers are not comparable with the table-based ones above and are never drawn on the same chart.

Total query time over Parquet, common queries (s)

Sum of warm medians over the queries every entry point ran correctly. Lower is better.

Details: explore the data, all charts, methodology and every setting.