Blazing fast TPCH benchmark data generator, in pure Rust with zero dependencies.
The easiest way to use this software is via the [tpchgen-cli] tool.
[tpchgen-cli] is more than 10x faster than the next fastest TPCH generator we
know of. On a 2023 Mac M3 Max laptop, it easily generates data faster than can
be written to SSD. See BENCHMARKS.md for more
details on performance and benchmarking.
Times to create TPCH tables in Parquet format using tpchgen-cli and duckdb for various scale factors.
| Scale Factor | tpchgen-cli |
DuckDB | DuckDB (proprietary) |
|---|---|---|---|
| 1 | 0:02.24 |
0:12.29 |
0:10.68 |
| 10 | 0:09.97 |
1:46.80 |
1:41.14 |
| 100 | 1:14.22 |
17:48.27 |
16:40.88 |
| 1000 | 10:26.26 |
N/A (OOM) | N/A (OOM) |

The core tpchgen crate provides answers for queries 1 to 22 and for a scale factor
of 1. The answers exposed were derived from the TPC-H Tools
official distribution.
This crate has extensive tests to ensure correctness and produces exactly the
same, byte-for-byte output as the original [dbgen] implementation. We compare
the output of this crate with [dbgen] as part of every checkin. See
TESTING.md for more details on testing methodology
tpchgen: the core data generator logic for TPC-H. It has no
dependencies and is easy to embed in other Rust project.
tpchgen-arrow generates TPC-H data in Apache Arrow
format. It depends on the arrow-rs library
tpchgen-cli is a [dbgen] compatible CLI tool that generates
benchmark dataset using multiple processes.
Pull requests are welcome. For major changes, please open an issue first for discussion. See our contributors guide for more details.
Please see architecture guide for details on how the code is structured.
The project is licensed under the APACHE 2.0 license.
$ claude mcp add tpchgen-rs \
-- python -m otcore.mcp_server <graph>