CSV to SQL INSERT Statements
NEWPaste a CSV and get SQL INSERT statements for MySQL, PostgreSQL, SQLite or MS SQL — optionally with a CREATE TABLE preamble (column types are inferred from the data). Multi-value INSERT mode collapses everything into one statement.
More options
How to use CSV to SQL
- Paste your CSV.
- Set table name and dialect.
- Optionally enable CREATE TABLE.
- Click Generate SQL.
What is CSV to SQL?
Each cell value is quoted appropriately — numbers stay unquoted, NULL handled, booleans recognized. Identifier escaping follows the chosen dialect (backticks for MySQL, double-quotes for Postgres, brackets for MSSQL).
FAQ
- How are column types inferred?
- Per-column heuristic: all-integer → INTEGER, all-numeric → DECIMAL, all-boolean → BOOLEAN, short strings → VARCHAR(255), longer → TEXT.
Related tools
Last updated: