SQLDumpSplitter » Use cases » Backup archiving by table
Download SQLDumpSplitter Free Trial » Buy SQLDumpSplitter Now »
Retention is never uniform. The audit log and the ledger have to be kept for years - possibly by law - while the session table, the cache table and last quarter's staging data can go after a month. But the monthly backup is one .sql file per database, so the only choice is to keep everything or throw everything away.
It also makes the archive unreadable in practice: a 20 GB dump per month has no single table you can pull out of it later, and restoring one table means importing the entire file into a scratch database first.
.sql file.
Each file is still valid SQL and runs on its own, because the split follows the dump's own statement boundaries. The original dump is left exactly as it was, so this is a non-destructive extra step - split a copy, and keep the original if you prefer.
Splitting: by table, by file size, by row count. Producing the dump from a live database: DBToFile. Cutting other kinds of files by value: DataFileSplitter.