[ Web Proxy ]
URL:
Viewing: https://sql-splitter.dev/ [Back]  [Original]

sql-splitter - High-Performance SQL Dump Toolkit in Rust

;sql-splitter

SQL dump toolkit at ~1 GB/s

Split, merge, convert, validate, sample, shard, diff, redact, query, and generate synthetic data from SQL dump files. MySQL, PostgreSQL, SQLite, and MSSQL. Written in Rust.

Get StartedView on GitHub

Why sql-splitter?

Working with large SQL dumps is painful. Importing a 10GB file takes forever, and you often just need a few tables. sql-splitter lets you split the dump into individual files so you can import only what you need.

~

Blazing Fast

~1 GB/s throughput

<

Memory Efficient

~20150 MB, size-independent

*

Multi-Dialect

MySQL, PostgreSQL, SQLite, MSSQL

13 Powerful Commands

splitSplit dump into per-table filesmergeCombine files back into one dumpanalyzeView table statisticsvalidateCheck integrity and syntaxconvertTransform between dialectssampleCreate reduced datasetsshardExtract tenant datadiffCompare two dumpsredactAnonymize PII datagraphGenerate ERD diagramsorderTopological FK orderingquerySQL analytics with DuckDBgenerateSynthetic data from your schema

Quick Start

Get up and running in seconds.

1

Install

curl
curl -fsSL https://sql-splitter.dev/install.sh | sh
Copy
brew
brew install helgesverre/tap/sql-splitter
Copy
cargo
cargo install sql-splitter
Copy

Windows, pre-built binaries, and more in the install guide.

2

Split your dump

sql-splitter split database.sql --output=tables
Copy
3

Work with individual tables

# Each table gets its own .sql file
ls tables/
# users.sql orders.sql products.sql ...

Common Workflows

Database Migration

# Convert MySQL to PostgreSQL
sql-splitter convert mysql.sql --to postgres -o postgres.sql

# Stream directly to database
sql-splitter convert mysql.sql.gz --to postgres -o - | psql "$PG_CONN"
Copy

Create Dev Dataset

# Sample 10% with FK integrity preserved
sql-splitter sample prod.sql -o dev.sql --percent 10 --preserve-relations

# Anonymize sensitive data
sql-splitter redact dev.sql -o safe.sql --hash "*.email" --fake "*.name"
Copy

CI/CD Validation

# Validate all dumps with JSON output
sql-splitter validate "dumps/*.sql" --strict --json --fail-fast
Copy

Ready to get started?

Read the DocsStar on GitHub

GitHub|Releases|MIT License|llms.txt

Built by Helge Sverre


Web Proxy Viewer  |  New URL  |  Original Page