Taming PgAdmin's SQL Formatting

williamlake

William Lake

Posted on March 31, 2022

Taming PgAdmin's SQL Formatting

Unformatted

The example query I'm using came from here.

Qualifiers

I really appreciate PgAdmin and everyone who's built it.

Who knows what I'd be doing without their hard work.

More Qualifiers

I haven't read every line of their documentation. Maybe their setup instructions include this on the very first page. Maybe they've surrounded it with exclamation points and made it bold & red. The point is, if they did- I missed it. If you find this helpful- great! If not, that's ok too. Take what works and leave the rest. Or don't, I'm not the cops.

Getting to the Point

Very Compact SQL

Option Value
Re-indent aligned? True
Re-indent? False
Spaces around operators? False
Tab size 2
Use spaces? True

Compact Format

Less Compact Easier to Read

Option Value
Re-indent aligned? True
Re-indent? True
Spaces around operators? False
Tab size 2
Use spaces? True

Less Compact Format

💖 💪 🙅 🚩
williamlake
William Lake

Posted on March 31, 2022

Join Our Newsletter. No Spam, Only the good stuff.

Sign up to receive the latest update from our blog.

Related

Taming PgAdmin's SQL Formatting
postgres Taming PgAdmin's SQL Formatting

March 31, 2022