What it is
Formatting breaks a SQL query onto multiple lines around its major clauses (SELECT, FROM, WHERE, JOIN, and so on) with consistent indentation and keyword casing, making long queries easier to scan and review.
When to use it
Use this when a query copied from logs, an ORM, or a colleague's message is a single unreadable line, or before pasting a query into a code review or documentation.
Gotchas & limits
This is a lightweight, regex-based formatter rather than a full SQL parser, so it doesn't understand every dialect-specific construct and won't catch semantic errors in the query.