1. Beautifying a Complex PostgreSQL Analytics Query
Data AnalystBackground
A data analyst has a long, unformatted PostgreSQL query with multiple joins and aggregations that is difficult to read and debug.
Problem
The query is written in a single block with mixed casing and inconsistent spacing.
How to use
Paste the raw query into the input, select 'PostgreSQL' as the dialect, set keyword casing to 'UPPER', and choose standard indentation with a width of 2.
Mode: Format, Dialect: PostgreSQL, Keyword Case: UPPER, Indent Style: Standard, Indent Width: 2Outcome
The query is formatted with clear line breaks for JOIN, WHERE, and GROUP BY clauses, and all keywords are capitalized for readability.