Excel to SQL INSERT Generator
Generate SQL INSERT statements from Excel or CSV rows for seed data, database import, staging tables, and test environments.
Best fit for INSERT scripts
Use INSERT when each spreadsheet row represents a new record that should be added to a database table, such as users, products, locations, or configuration rows.
Prepare your spreadsheet
Put column names in the first row and data from the second row onward. Keep column names close to database fields and remove columns that should not be imported.
Batch INSERT and CREATE TABLE
For larger imports, enable batch insert to combine multiple VALUES rows. Enable CREATE TABLE when you need a starter table definition or a temporary staging table.
NULL, strings, and dates
Blank cells and NULL text become SQL NULL. Strings are escaped, and the generated SQL adapts to SQL Server, MySQL, PostgreSQL, SQLite, or Oracle.
Example: Excel to INSERT statements
Sample spreadsheet
City,Population,Region
Shanghai,24870000,East
Shenzhen,17680000,South
Generated INSERT script
INSERT INTO dbo.Cities (City, Population, Region) VALUES ('Shanghai', 24870000, 'East');
INSERT INTO dbo.Cities (City, Population, Region) VALUES ('Shenzhen', 17680000, 'South');
FAQ
Can one Excel row become one INSERT statement?
Yes. Each data row can generate one INSERT statement. You can also enable batch insert to combine many rows into one statement.
Can I choose only some columns?
Yes. In the mapping matrix, check only the columns you want to include in the INSERT script.
Can the tool generate CREATE TABLE too?
Yes. Enable the CREATE TABLE option when you need a table definition before the INSERT statements.