pg_ducklake
Overview
| Package | Version | Category | License | Language |
|---|---|---|---|---|
pg_ducklake | 1.0.0 | OLAP | MIT | C++ |
| ID | Extension | Bin | Lib | Load | Create | Trust | Reloc | Schema |
|---|---|---|---|---|---|---|---|---|
| 2490 | pg_ducklake | No | Yes | Yes | Yes | No | No | ducklake |
| Related | pg_lake pg_duckdb pg_mooncake pg_parquet duckdb_fdw aws_s3 file_fdw pg_bulkload columnar pg_clickhouse |
|---|
Version
| Type | Repo | Version | PG Ver | Package | Deps |
|---|---|---|---|---|---|
| EXT | PIGSTY | 1.0.0 | 1817161514 | pg_ducklake | - |
| RPM | PIGSTY | 1.0.0 | 1817161514 | pg_ducklake_$v | - |
| DEB | PIGSTY | 1.0.0 | 1817161514 | postgresql-$v-pg-ducklake | - |
Build
You can build the RPM / DEB packages for pg_ducklake using pig build:
Install
You can install pg_ducklake directly. First, make sure the PGDG and PIGSTY repositories are added and enabled:
Install the extension using pig or apt/yum/dnf:
Preload:
Create Extension:
Usage
Sources: README, v1.0.0 release, project docs
pg_ducklake adds DuckLake tables to PostgreSQL. DuckLake metadata lives in PostgreSQL while table data is stored in Parquet and queried through DuckDB, giving PostgreSQL SQL clients access to lakehouse features such as snapshots, time travel, partitioning, sort keys, and external object storage.
Create A DuckLake Table
Set a table path explicitly when data should live outside the default path:
Time Travel
Each commit creates a snapshot. Capture a snapshot id before a change, then query the older state:
Convert And Load Data
Create DuckLake tables from existing PostgreSQL heap tables or external data readers:
Inlining, Partitioning, And Maintenance
Small writes are inlined in metadata by default to avoid creating many tiny Parquet files. Tune the row limit or flush explicitly:
Partition and sort tables for pruning and analytics:
Run maintenance on demand when automatic background maintenance is not enough:
External DuckDB Access
DuckDB clients can attach the same DuckLake metadata:
Caveats
- Version 1.0.0 supports PostgreSQL 14-18.
- The README lists Ubuntu 22.04-24.04 and macOS as source-build targets.
- Cloud credentials are stored through a
ducklake_secretforeign server and per-user mappings; protect those catalog objects like other database secrets. - For incremental heap-to-DuckLake conversion, upstream points to the separate
pg_duckpipeproject.
Was this page helpful?
Thanks—your feedback helps us improve this page.
What got in the way? (optional)