DuckDB is an in-process SQL OLAP database management system
What is DuckDB?
DuckDB is a relational (table-oriented) DBMS that supports the Structured Query Language (SQL).
DuckDB is designed to support analytical query workloads, also known as Online analytical processing (OLAP). These workloads are characterized by complex, relatively long-running queries that process significant portions of the stored dataset, for example aggregations over entire tables or joins between several large tables. Changes to the data are expected to be rather large-scale as well, with several rows being appended, or large portions of tables being changed or added at the same time.
DuckDB has no external dependencies, neither for compilation nor during run-time. For releases, the entire source tree of DuckDB is compiled into two files, a header and an implementation file, a so-called “amalgamation”. This greatly simplifies deployment and integration in other build processes. For building, all that is required to build DuckDB is a working C++11 compiler.
For DuckDB, there is no DBMS server software to install, update and maintain. DuckDB does not run as a separate process, but completely embedded within a host process. For the analytical use cases that DuckDB targets, this has the additional advantage of high-speed data transfer to and from the database. In some cases, DuckDB can process foreign data without copying. For example, the DuckDB Python package can run queries directly on Pandas data without ever importing or copying any data.
Features
- Open-source and free
- Developer-friendly documentation
- Transactions, persistence
- Extensive SQL support
- Direct Parquet & CSV querying
- In-process, serverless
- C++11, no dependencies, single file build
- Fast and extremely lightweight
- Optimized for analytics
- Processing and storing tabular datasets, e.g. from CSV or Parquet files
- Interactive data analysis, e.g. Joining & aggregate multiple large tables
- Concurrent large changes, to multiple large tables, e.g. appending rows, adding/removing/updating columns
- Large result set transfer to client
- Parallel query processing
- Built-in API
- Several native clients for Python, Java, R, C++, C, Node.js, WASM, and a CLI app
- Built-in bulk-optimized Multi-Version Concurrency Control (MVCC).
- CPU optimized
- Supports OLAP queries
When to not use DuckDB?
- High-volume transactional use cases (e.g., tracking orders in a webshop)
- Large client/server installations for centralized enterprise data warehousing
- Writing to a single database from multiple concurrent processes
License
The project is released under the MIT License.