Open examples, checks, and related tools only after the primary input/output flow is done.
Guides
Examples
Starting points for this utility
select id,name from users where active=1 order by created_at descselect count(*) from orders where created_at >= '2026-01-01'select u.id,o.total from users u join orders o on o.user_id=u.id
Use cases
Code
Pretty-print compact SQL and copy a query review report before running it.
SQL Formatter for code workflows
Review the formatted query against the original before running it.
Redact literals and internal identifiers before sharing the formatted SQL.
Use Text Diff when comparing query revisions after formatting.
SQL examples
Statements
1
Input bytes
113
Output lines
10
Dialect
PostgreSQL
SQL diagnostics
Review query shape, table references, clauses, and copy risks before running formatted SQL.
Query type
SELECT query
Table references
2
JOIN clauses
1
Subqueries
0
Parameters
0
Sensitive fields
0
WHERE: YesLIMIT: NoJOIN: YesGROUP BY: NoORDER BY: YesRETURNING: No
Table references
First table-like references detected from FROM, JOIN, UPDATE, INSERT, or DELETE clauses.
usersorders
Review notes
No trailing semicolon detected. Add one if your SQL client expects statement terminators.
SELECT query has no LIMIT or aggregation. Add a limit before ad-hoc production checks.
SQL review report
Copy a handoff report with query shape, table references, clause checks, warnings, and a safe execution checklist.
Query type
SELECT query
Statements
1
Table references
2
JOIN clauses
1
Subqueries
0
Parameters
0
WHERE status
Yes
LIMIT status
No
Review notes
No trailing semicolon detected. Add one if your SQL client expects statement terminators.
SELECT query has no LIMIT or aggregation. Add a limit before ad-hoc production checks.
Review checklist
Run the query against staging or a transaction-wrapped session before production.
Confirm WHERE, LIMIT, and JOIN keys match the intended row set.
Use EXPLAIN or the database query plan for expensive SELECT or JOIN queries.
Wrap UPDATE, DELETE, INSERT, and schema changes in a reviewed migration or rollback plan.
Redact credentials, customer identifiers, and production literals before sharing.
# SQL review report
- Checked at: Browser copy time
- Output mode: Pretty print
- Query type: SELECT query
- Statements: 1
- Table references: 2
- JOIN clauses: 1
- Subqueries: 0
- Parameters: 0
- Sensitive fields: 0
- WHERE status: Yes
- LIMIT status: No
- Mutation or schema risk: No
- Input bytes: 113
- Output lines: 10
- Raw SQL is excluded from this report; attach a redacted formatted query separately if needed.
## Table references
- users
- orders
## Review notes
- No trailing semicolon detected. Add one if your SQL client expects statement terminators.
- SELECT query has no LIMIT or aggregation. Add a limit before ad-hoc production checks.
## Review checklist
- Run the query against staging or a transaction-wrapped session before production.
- Confirm WHERE, LIMIT, and JOIN keys match the intended row set.
- Use EXPLAIN or the database query plan for expensive SELECT or JOIN queries.
- Wrap UPDATE, DELETE, INSERT, and schema changes in a reviewed migration or rollback plan.
- Redact credentials, customer identifiers, and production literals before sharing.
Output
Pretty print
Copy-ready output
select
u.id,
o.total
from
users u
join orders o on o.user_id = u.id
where
o.status = 'paid'
order by
o.created_at desc