Extract Data from SQL Dumps Without a Database
You’ve got a .sql dump file with INSERT statements. Maybe it’s from a database backup, a migration script, or a seed file someone committed to Git. You need the data in a spreadsheet, but you don’t want to spin up a database just to SELECT it out.
Paste the INSERT statements here and get clean CSV with column headers and properly extracted values. The parser handles quoted strings containing commas, parentheses or semicolons, escaped quotes ('' and MySQL’s \'), unquoted numbers, NULL values, comments, and multi-row VALUES clauses. Multiple INSERT statements? It processes them all, and when they target different tables you pick the table from a list, so rows never end up under another table’s headers.
How It Parses
INSERT INTO users (name, age, city) VALUES
('John', 30, 'New York'),
('Jane', 25, 'London');
Becomes:
name,age,city
John,30,New York
Jane,25,London
Column names come from the INSERT column list. A mysqldump-style INSERT INTO t VALUES (...) without one takes its names from a CREATE TABLE for that table earlier in the paste, or falls back to col1, col2, and so on. Strings get their surrounding quotes stripped. Numbers stay as-is. A bare NULL becomes an empty cell, while an empty string is written as "" and the quoted text 'NULL' stays the word NULL, so the three never get confused.
Real Scenarios
Reviewing database backups. Your DBA exported a table as INSERT statements. The project manager wants to see the data in a spreadsheet. Convert it here instead of setting up a database to import it.
Comparing migrations. You’ve got two migration files from different branches. Convert both to CSV and diff them in a spreadsheet. Much easier than comparing raw SQL.
Extracting seed data. Your test seed file has 200 rows of INSERT statements. Convert to CSV so you can edit the data in Excel, then convert back with the CSV to SQL tool.
Non-technical handoff. A stakeholder needs to review the data in your SQL script but can’t read SQL. CSV opens in Excel, and everyone knows Excel.
The parser handles standard INSERT INTO ... VALUES syntax. It won’t work with subqueries, CASE expressions, stored procedures, or SELECT statements. It’s specifically for extracting data from INSERT statements — the most common format in dumps and seed files.
The CSV to SQL tool goes the reverse direction. The CSV to JSON tool converts the output to JSON for further processing.
All conversion runs client-side. Your SQL data stays in your browser.