DevToolsmith

Browser-based tools

SQL Tools

Make a long query readable, load a few files into a local database, generate inserts for a fixture or turn a schema into a diagram. Queries run in SQLite compiled to WebAssembly on this device.

Query locally

Format and convert

Data files

Common SQL workflows

SQL dialects differ in quoting, types and functions. A formatter changes layout but not meaning; an INSERT generator has to choose types and how to write NULL. SQLite is dynamically typed, so a query that works here may need casts in PostgreSQL or MySQL.

Move spreadsheet rows into a database

Generate INSERT statements from CSV or JSON. Choose the target SQL dialect and review NULL handling and inferred types before running SQL yourself.

  • CSV to SQL — Turn CSV into CREATE TABLE and INSERT statements.
  • JSON to SQL — Turn a JSON array into CREATE TABLE and INSERT statements.
  • SQL Formatter — Beautify SQL queries in 16 dialects.

Query local files with SQL

Import CSV or JSON as tables in an in-browser SQLite database, join them and export the result. The file is not uploaded.

Extract rows from a SQL dump

Turn INSERT statements from a dump or migration into JSON records or CSV rows without running them. Pick the table when a file inserts into several.

  • SQL to JSON — Turn SQL INSERT statements into JSON records.
  • SQL to CSV — Extract CSV rows from SQL INSERT statements.
  • JSON to CSV — Convert JSON arrays to CSV, flattening nested objects.

Document a schema

Paste CREATE TABLE statements to draw an entity-relationship diagram in Mermaid, and format the DDL for review.

Pick the dialect you will run

Identifier quoting, boolean literals and upsert syntax differ between PostgreSQL, MySQL, SQLite and SQL Server. Generated statements follow the dialect you choose.

Review generated SQL before running it

Generators never connect to your database. Read the statements, check types and run them in a transaction you can roll back.

Frequently asked questions

Can I query a CSV file without installing a database?

Yes. The SQLite Database Lab runs SQLite compiled to WebAssembly in your browser. Import the CSV as a table, run SQL and export the result; the file is not uploaded.

Does the formatter change what my query does?

It should only change whitespace, line breaks and keyword case. Compare the formatted query with the original when it contains dialect-specific syntax the formatter may not know.

Can I query a local file without uploading it?

Yes. SQLite Database Lab imports CSV and JSON as local tables, and DuckDB SQL Lab queries Parquet, CSV and JSON in a browser worker. Data File Lab pages through NDJSON, Parquet, Avro and Protobuf files with bounded reads.

Tools process your input on this device. Read the privacy policy, or save the tool library for offline use.