Docs/Engines/DuckDB

DuckDB

DuckDB is embedded like SQLite, with transactional DDL and no credentials. It suits local rehearsal and analytics-side schema work.

type
duckdb
Driver
duckdb_engine
DDL
Transactional
Default schema
main

Install

pip install "dblift[duckdb]"

Connection URL

duckdb:///app.duckdb

duckdb:///rel.db is relative, duckdb:////abs.db absolute, duckdb:///:memory: in-memory. A bare file path is accepted in path.

dblift.yaml

database:
  type: duckdb
  path: "./app.duckdb"
  schema: "main"

Engine settings

KeyDefaultEffect
path—The database file, or :memory:. Taken from path, then url, then database.
schemamainDuckDB's default schema.
username / password—Not required.

Behaviour notes

DDL is transactional.

DuckDB is MVCC and ACID, so a failed migration rolls back.

DROP TABLE … CASCADE is available.

Foreign keys held by other tables still need dropping first — DBLift enumerates objects before a clean.

Row counts are not reported.

The driver returns -1 for DML, so DBLift confirms an operation by re-querying instead of trusting the count.

History ranking uses a sequence.

installed_rank is populated from a DuckDB sequence.