منسّق SQL
تنسيق استعلامات SQL مع لهجات
Input
Formatted Output
Make complex SQL queries readable in seconds
Long SQL queries — multiple JOINs, CTEs, nested subqueries, window functions — quickly become unreadable when written on a few long lines. A formatter inserts line breaks, indents subqueries, and aligns clauses so you can review logic, debug joins, or share queries in tickets without losing your mind.
Use the formatter when you need to
Review a complex analytical query
Format a multi-CTE query so each step's logic is visible without horizontal scrolling.
Document SQL in a runbook or ticket
Clean up the query so future readers can scan it without replaying the whole thing in their head.
Debug a slow query
Format before reading EXPLAIN output so the structure of the query is clear to compare against the plan.
How to format SQL quickly
- 1
Paste your query into the editor.
- 2
Pick a SQL dialect if needed (PostgreSQL, MySQL, SQL Server, etc.).
- 3
Click Format and copy the indented result.
Keep going
Format JSON results
Beautify the output of jsonb columns or row_to_json calls returned by your query.
Format CSS
Add CSS formatting to your toolkit alongside SQL.
Format JavaScript
Format scripts that build SQL strings or process query results.
Format HTML
Format markup that displays query results in admin tools.
Common SQL-formatting workflows
Format before pasting into a ticket so the reviewer can read the logic in seconds.
ORM-generated SQL is often long and dense — format to confirm what actually runs.
Document a recovery query so the next on-caller can read and adapt it under pressure.
أدوات ذات صلة
الأسئلة الشائعة
The formatter handles standard SQL plus dialect-specific syntax for PostgreSQL, MySQL, SQL Server, SQLite, BigQuery, and Snowflake. Choose the dialect that matches your database for the most accurate formatting.
No. Formatting only changes whitespace and line breaks. The query that runs is identical — only readability changes. Comments, hints, and dialect-specific syntax are preserved.
Yes. Common Table Expressions (WITH clauses), window functions (OVER, PARTITION BY), and recursive CTEs format with appropriate indentation so each clause's logic is easy to follow.
The formatter targets queries (SELECT, INSERT, UPDATE, DELETE, CREATE, etc.). Stored procedure bodies with control flow (IF, WHILE, BEGIN/END) format reasonably for most dialects but may need manual cleanup for complex procedural code.
No. Formatting happens entirely in your browser. Your SQL — including any sensitive table or column names — never leaves your machine.