News for hackers. Stuff that matters.
Re:SQL Tips and Tricks by swarnie on Wednesday September 25, 2024 @02:16AM (#41644207)
Alternatively, write a mess of SQL like a three year old child that just discovered MSPaint then push the "beautifier" button and knock off for an early lunch.
Re:SQL Tips and Tricks by password4321 on Thursday September 26, 2024 @12:39AM (#41654607)
Where am I supposed to park my bike if the shed is gone?!

Closer to more seriously: which "beautifier" button is best? Is there a free one that is close to industry standard?

Re:SQL Tips and Tricks by swarnie on Thursday September 26, 2024 @03:11AM (#41655375)
I can't really answer that i'm afraid, my chosen IDE (PL/SQL Dev) comes with one as standard.
Re:SQL Tips and Tricks by NortySpock on Thursday September 26, 2024 @11:20AM (#41659409)
SQLFluff is a linter formatter written in Python https://sqlfluff.com/

Heard there is a faster one called sqruff, but I have not tried it

https://www.quary.dev/blog/sqruff-launch

Might also be able to cajole sqlglot into being a formatter but it's designed for forgiving dialect conversion, not formatting

https://github.com/tobymao/sqlglot