Skip to main content

TPC-H Data Generator CLI

tpchgen-cli is a high-performance, parallel command line interface for generating TPC-H data.

Note: See tpcgen-cli to create both TPC-H and TPC-DS data and the tpcgen-rs project for the full project details.

This tool is more than 10x faster than the next fastest TPC-H generator we know of (duckdb). 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.

Try with uvx

uvx tpchgen-cli parquet -s 1 --output-dir /tmp/tpch

Running tpchgen-cli

Install with pip

python -m pip install tpchgen-cli

Install via Rust

Install Rust and compile

curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
RUSTFLAGS='-C target-cpu=native' cargo install --locked tpchgen-cli

Then generate TPC-H data:

tpchgen-cli parquet -s 1 --output-dir /tmp/tpch

Examples

# Scale Factor 10, all tables, in Apache Parquet format in the current directory
# (3.6GB, 8 files, 60M lineitem rows, in 5 seconds on a modern laptop)
tpchgen-cli parquet -s 10

# Scale Factor 10, all tables, in `tbl`(csv like) format in the `sf10` directory
# (10GB, 8 files, 60M lineitem rows)
# Note: `tpchgen-cli tbl` also works explicitly
tpchgen-cli -s 10 --output-dir sf10

# Scale Factor 1000, lineitem table, in Apache Parquet format in sf1000 directory,
# 20 part(itions), 100MB row groups
# (220GB, 20 files, 6B lineitem rows, 3.5 minutes on a modern laptop)
tpchgen-cli parquet -s 1000 --tables lineitem --parts 20 --row-group-bytes=100MB --output-dir sf1000

# Per-column encodings (overrides Parquet writer defaults for named columns)
tpchgen-cli parquet -s 1 --tables lineitem --column-encoding=l_comment=DELTA_LENGTH_BYTE_ARRAY,l_shipinstruct=DELTA_LENGTH_BYTE_ARRAY

# Scale Factor 10, partition 2 and 3 of 10 in partitioned directory
#
# partitioned/
# ├── lineitem
# │   ├── lineitem.2.tbl
# │   └── lineitem.3.tbl
# └── orders
#    ├── orders.2.tbl
#    └── orders.3.tbl
#
for PART in `seq 2 3`; do
  tpchgen-cli --tables lineitem,orders --scale-factor=10 --output-dir partitioned --parts 10 --part $PART
done

By default tpchgen-cli shows a per-table progress bar on stderr while data is generated. Pass --no-progress to disable it (it is also disabled automatically when --quiet is set, when --stdout is used, or when stderr is not a terminal, e.g. in CI logs).

Performance

Times to create TPC-H 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)
  • DuckDB (proprietary) is the time required to create TPC-H data using the proprietary DuckDB format
  • Creating Scale Factor 1000 using DuckDB required 647 GB of memory, which is why it is not included in the table above.

Parquet Generation Performance

More information

  • Watch this demo by @alamb to see tpchgen-cli in action
  • Read the companion blog post in the DataFusion blog to learn about the project's history

References

  • The TPC-H Specification, see the specification page.
  • The Original dbgen Implementation you must submit an official request to access the software dbgen at their official website

Metadata

Release files for tpchgen-cli 4.0.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for tpchgen-cli 4.0.0
File Size Uploaded Provenance Actions
tpchgen_cli-4.0.0.tar.gz 610.1 kB Without provenance Details for tpchgen_cli-4.0.0.tar.gz

Built distributions (wheels)

Table of built distributions (wheels) for tpchgen-cli 4.0.0
File Actions
tpchgen_cli-4.0.0-py3-none-win_amd64.whl Python 3 none Windows x86-64 Details for tpchgen_cli-4.0.0-py3-none-win_amd64.whl
tpchgen_cli-4.0.0-py3-none-win32.whl Python 3 none Windows x86-32 Details for tpchgen_cli-4.0.0-py3-none-win32.whl
tpchgen_cli-4.0.0-py3-none-musllinux_1_2_x86_64.whl Python 3 none Linux musl 1.2+ x86-64 Details for tpchgen_cli-4.0.0-py3-none-musllinux_1_2_x86_64.whl
tpchgen_cli-4.0.0-py3-none-musllinux_1_2_i686.whl Python 3 none Linux musl 1.2+ x86-32 Details for tpchgen_cli-4.0.0-py3-none-musllinux_1_2_i686.whl
tpchgen_cli-4.0.0-py3-none-musllinux_1_2_armv7l.whl Python 3 none Linux musl 1.2+ ARMv7l Details for tpchgen_cli-4.0.0-py3-none-musllinux_1_2_armv7l.whl
tpchgen_cli-4.0.0-py3-none-musllinux_1_2_aarch64.whl Python 3 none Linux musl 1.2+ ARM64 Details for tpchgen_cli-4.0.0-py3-none-musllinux_1_2_aarch64.whl
tpchgen_cli-4.0.0-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl Python 3 none Linux glibc 2.17+ x86-64 Details for tpchgen_cli-4.0.0-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
tpchgen_cli-4.0.0-py3-none-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl Python 3 none Linux glibc 2.17+ PowerPC 64-le Details for tpchgen_cli-4.0.0-py3-none-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl
tpchgen_cli-4.0.0-py3-none-manylinux_2_17_i686.manylinux2014_i686.whl Python 3 none Linux glibc 2.17+ x86-32 Details for tpchgen_cli-4.0.0-py3-none-manylinux_2_17_i686.manylinux2014_i686.whl
tpchgen_cli-4.0.0-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl Python 3 none Linux glibc 2.17+ ARMv7l Details for tpchgen_cli-4.0.0-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl
tpchgen_cli-4.0.0-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl Python 3 none Linux glibc 2.17+ ARM64 Details for tpchgen_cli-4.0.0-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
tpchgen_cli-4.0.0-py3-none-macosx_11_0_arm64.whl Python 3 none macOS 11.0+ ARM64 Details for tpchgen_cli-4.0.0-py3-none-macosx_11_0_arm64.whl
tpchgen_cli-4.0.0-py3-none-macosx_10_12_x86_64.whl Python 3 none macOS 10.12+ x86-64 Details for tpchgen_cli-4.0.0-py3-none-macosx_10_12_x86_64.whl

Total release size: 50.4 MB

Release files / tpchgen_cli-4.0.0.tar.gz

Download URL tpchgen_cli-4.0.0.tar.gz
Size 610.1 kB
Tags Source
SHA-256 checksum
How to use checksums
b75d3ec5f1e0ec84c58d8aafb89fea28e309bfb7875ab0e52bd5d48fc0aa09e1
BLAKE2b-256 checksum
How to use checksums
1361bca1d5db6074a3d62502ddfe7737d4bdfe05b319dec0f9b9bac809c4208b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via maturin/1.15.0

Release files / tpchgen_cli-4.0.0-py3-none-win_amd64.whl

Download URL tpchgen_cli-4.0.0-py3-none-win_amd64.whl
Size 3.9 MB
Tags Python 3 Windows x86-64
SHA-256 checksum
How to use checksums
722c750278e4ad658776468d54962ae4f5795894e1e894416cbec2520afe6192
BLAKE2b-256 checksum
How to use checksums
ce26f9fa7f9c37f05d203af52d3dfd9b025bae9b4a6219531a326b72c9adde3c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via maturin/1.15.0

Release files / tpchgen_cli-4.0.0-py3-none-win32.whl

Download URL tpchgen_cli-4.0.0-py3-none-win32.whl
Size 3.6 MB
Tags Python 3 Windows x86-32
SHA-256 checksum
How to use checksums
4a90ad52978c76c2791ea4d022994b4af80db64e920c60eac7ecda24b1d4493c
BLAKE2b-256 checksum
How to use checksums
871bc725fc54d4c1a914c93072fa175b19555511508c0050ff136e2897526004
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via maturin/1.15.0

Release files / tpchgen_cli-4.0.0-py3-none-musllinux_1_2_x86_64.whl

Download URL tpchgen_cli-4.0.0-py3-none-musllinux_1_2_x86_64.whl
Size 4.0 MB
Tags Linux musl 1.2+ x86-64 Python 3
SHA-256 checksum
How to use checksums
f1ae08506e6df411a4e5055f242685bd7f23ee3525d7d131a12a8a630207f307
BLAKE2b-256 checksum
How to use checksums
c4426d4184c74f69aa07ed29c61015df23280132a8949c66993d4716b8e010d1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via maturin/1.15.0

Release files / tpchgen_cli-4.0.0-py3-none-musllinux_1_2_i686.whl

Download URL tpchgen_cli-4.0.0-py3-none-musllinux_1_2_i686.whl
Size 3.9 MB
Tags Linux musl 1.2+ x86-32 Python 3
SHA-256 checksum
How to use checksums
29d9febb7d1b0d2cbee0e8dc38ff5c276436224e93a18a70fb2e4efc8d9b4680
BLAKE2b-256 checksum
How to use checksums
00d285300147ac6688dd0ef88eb6cc50e6e3ff149157166bf0253d3066926ca6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via maturin/1.15.0

Release files / tpchgen_cli-4.0.0-py3-none-musllinux_1_2_armv7l.whl

Download URL tpchgen_cli-4.0.0-py3-none-musllinux_1_2_armv7l.whl
Size 3.9 MB
Tags Linux musl 1.2+ ARMv7l Python 3
SHA-256 checksum
How to use checksums
5680fc7d5f55ffe44d88027c379be1e6ad0c5746d5e33a0bf8354f8deefe02a1
BLAKE2b-256 checksum
How to use checksums
5dad63d9bd66ecbf0fcf4803ec901a4052eeff3686c7e60475d5dbd7c6d03a64
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via maturin/1.15.0

Release files / tpchgen_cli-4.0.0-py3-none-musllinux_1_2_aarch64.whl

Download URL tpchgen_cli-4.0.0-py3-none-musllinux_1_2_aarch64.whl
Size 3.8 MB
Tags Linux musl 1.2+ ARM64 Python 3
SHA-256 checksum
How to use checksums
61c72ab59397c65f4b2f7e605ac412dbd18618886d6dbb16eb8151b9da8a45d3
BLAKE2b-256 checksum
How to use checksums
fc33926ae8ba0a078e104215a14db6cd32468f0642630ab23f47eab5d882b80c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via maturin/1.15.0

Release files / tpchgen_cli-4.0.0-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL tpchgen_cli-4.0.0-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 3.9 MB
Tags Linux glibc 2.17+ x86-64 Python 3
SHA-256 checksum
How to use checksums
19ee231140c9e8cc4caf981cc166186c638e11a33744e3d32cff5bd7f2ba44a2
BLAKE2b-256 checksum
How to use checksums
306814b1d2a0a46306d63077a81378f83bbbd3ddea58078ea41b4b6a6d7a8207
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via maturin/1.15.0

Release files / tpchgen_cli-4.0.0-py3-none-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl

Download URL tpchgen_cli-4.0.0-py3-none-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl
Size 4.1 MB
Tags Linux glibc 2.17+ PowerPC 64-le Python 3
SHA-256 checksum
How to use checksums
967b3ff015938376595220ff9a3b1e829f8c3501551ff579e768fe606eed1058
BLAKE2b-256 checksum
How to use checksums
87eeb4860cfe0e3deb242c43a2e69babdc9c2f9bfff0fec855bc68aeb0b10df0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via maturin/1.15.0

Release files / tpchgen_cli-4.0.0-py3-none-manylinux_2_17_i686.manylinux2014_i686.whl

Download URL tpchgen_cli-4.0.0-py3-none-manylinux_2_17_i686.manylinux2014_i686.whl
Size 3.9 MB
Tags Linux glibc 2.17+ x86-32 Python 3
SHA-256 checksum
How to use checksums
ddb4094e21f6dcfc3c9eaa707d6ebf7acee813d3933cf7c4ca3eb428424d759d
BLAKE2b-256 checksum
How to use checksums
958ab7553c5f6297ce69d5a456585434fc7c9630b8197ee34e9a652963bf64ca
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via maturin/1.15.0

Release files / tpchgen_cli-4.0.0-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl

Download URL tpchgen_cli-4.0.0-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl
Size 3.9 MB
Tags Linux glibc 2.17+ ARMv7l Python 3
SHA-256 checksum
How to use checksums
ed6e2f05d9f7282e0f2da4271d1571165e1ad74b7176fab46ed6bb0513a9ac12
BLAKE2b-256 checksum
How to use checksums
f767c38438390550cac621cd6cfa35534b9314a8f02c3da468f951a5f2c86465
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via maturin/1.15.0

Release files / tpchgen_cli-4.0.0-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl

Download URL tpchgen_cli-4.0.0-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Size 3.7 MB
Tags Linux glibc 2.17+ ARM64 Python 3
SHA-256 checksum
How to use checksums
ef02a06ad5e17448acf64979fbdf8fa484133df863e2749516a4dc29c55df00b
BLAKE2b-256 checksum
How to use checksums
1a0ec4428b5f299c0139cee6119833fb82fe47d263561835079889779998410f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via maturin/1.15.0

Release files / tpchgen_cli-4.0.0-py3-none-macosx_11_0_arm64.whl

Download URL tpchgen_cli-4.0.0-py3-none-macosx_11_0_arm64.whl
Size 3.5 MB
Tags Python 3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
e6883a74e88607322462f1cdc9d2864dc948ecf2f25d235969dd3020887e6f5b
BLAKE2b-256 checksum
How to use checksums
0580e8496b6bce2b825955919abb85787707261017f4e2a6a059f4dd6ff855cc
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via maturin/1.15.0

Release files / tpchgen_cli-4.0.0-py3-none-macosx_10_12_x86_64.whl

Download URL tpchgen_cli-4.0.0-py3-none-macosx_10_12_x86_64.whl
Size 3.7 MB
Tags Python 3 macOS 10.12+ x86-64
SHA-256 checksum
How to use checksums
04260113d9ff7f63dd6defac059c176ed225a93fd53b67460065b6b544935512
BLAKE2b-256 checksum
How to use checksums
f673e2b63d2af7cb52f5cdd26526327a7e28319ec16e4a8ecff349b1c02f0291
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via maturin/1.15.0

Security for tpchgen-cli 4.0.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page