top | item 10868079

Writing more legible SQL

3 points| craigkerstiens | 10 years ago |craigkerstiens.com | reply

3 comments

order
[+] creager|10 years ago|reply
I'll admit to giving little thought to the legibility of my SQL - this is a quick read, with some solid tips.

Do you do anything in particular to make your queries more digestible?

[+] ThatMightBePaul|10 years ago|reply
Craig mentions this in the piece, but I'll second it:

I fucking love CTE's for breaking apart ugly looking queries. They make everything significantly easy to read.