SQL Query Builder
Describe the query. Get the syntax. No dialect memorized required.
Tables
Define a table's columns once — pickers everywhere else in the builder will use it. Skip this and type table/column names freely instead.
Columns
Aggregates
Adds a function over a column to the SELECT list.
Joins
Where
Group By
Having
Reference an aggregate above, e.g. COUNT(id).
Order By
Columns & Values
Extra Value Rows
For inserting more than one row at once.
Set
Where
Where
What this SQL query builder does
This tool turns SELECT, INSERT, UPDATE and DELETE statements into a guided form instead of a blank text box. Define a table's columns once, then pick columns, add WHERE conditions, joins, GROUP BY and ORDER BY visually. The SQL updates as you go, correctly quoted for MySQL, PostgreSQL, SQL Server, SQLite or standard SQL.
It's built for anyone who writes SQL occasionally and doesn't want to re-learn each dialect's quirks — analysts, backend developers, students, or anyone double-checking a query before running it against a real database. Everything runs locally in your browser; table names, column names and sample values you type here are never sent anywhere.
How to use it
- Add a table and its columns above, typed manually or detected from a CSV header row.
- Choose a statement type: SELECT, INSERT, UPDATE or DELETE.
- Build the query with checkboxes, dropdowns and condition rows for WHERE, JOIN, GROUP BY and ORDER BY.
- Copy the generated SQL, or save it as a named snippet to reuse later.
Frequently asked questions
Does this tool run my SQL against a real database?
No. It only generates SQL text based on what you configure here — it never connects to or executes anything against a database. Copy the result into your own database client to run it.
Which SQL dialects are supported?
Standard SQL, MySQL, PostgreSQL, SQL Server and SQLite. Switching dialects changes identifier quoting (backticks, double quotes or brackets) and pagination syntax, such as LIMIT/OFFSET versus TOP or OFFSET/FETCH.
Can I build joins, aggregates and subqueries?
Yes. The SELECT tab includes a join builder with a visual diagram, GROUP BY with COUNT/SUM/AVG/MIN/MAX aggregates and a HAVING clause, and subquery or EXISTS/NOT EXISTS support inside WHERE and HAVING conditions.
Is my data saved anywhere?
Table definitions and saved snippets are stored only in your browser's local storage. Nothing is uploaded to a server, and clearing your browser data clears them too.