Docomint

Formateador de SQL

Da formato legible a una consulta SQL de una sola línea, convirtiéndola en SQL multilínea con sangría.

🔒 Processed on your device

What is a Formateador de SQL?

Breaks a dense, single-line SQL query into a readable multi-line layout — each major clause (SELECT, FROM, WHERE, JOIN, ORDER BY, and similar) starts its own line — using keyword-based formatting rather than a full SQL parser, so it works across dialects but won't understand every vendor-specific construct perfectly.

How to use the Formateador de SQL

  1. Paste a SQL query, however it's currently formatted
  2. Major clauses (SELECT, FROM, WHERE, JOIN, and more) are broken onto their own line, instantly on your device
  3. Copy the readable result

Example

"select id, name from users where active = 1 order by name" becomes a 3-line query with SELECT, FROM, and ORDER BY each on their own line.

Frequently asked questions

Does this validate that my SQL is correct?

No — it only reformats based on keyword matching, without parsing or checking syntax. A query with a typo or logic error will be reformatted just as readily as a correct one.

Is my data uploaded anywhere?

No — Formateador de SQL runs entirely in your browser using JavaScript/WebAssembly. Your data is never sent to a server.

Does this work for any SQL dialect — MySQL, PostgreSQL, T-SQL?

Yes for basic formatting, since it works by recognizing standard keywords rather than parsing a specific dialect's grammar — vendor-specific syntax still gets broken onto new lines correctly even though it isn't specifically validated.

Related tools