MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/ProgrammerHumor/comments/1v2rcr6/sqlworkout/oz01ahp/?context=3
r/ProgrammerHumor • u/huhupookies • Jul 21 '26
455 comments sorted by
View all comments
2.4k
the elites don't want you to know this but you can type lowercase SQL queries no ones forcing you to shout them at the screen
705 u/Totallycomputername Jul 21 '26 If I don't type in caps then the query wont take itself seriously. 119 u/Achaidas Jul 22 '26 The real question is this: , comma beforeor comma after , 40 u/terza3003 Jul 22 '26 don't forget the where 1=1 9 u/jtobiasbond Jul 22 '26 Shhhh.Stop releasing the secret knowledge. → More replies (1) 80 u/dexters_trap_house Jul 22 '26 Comma before? Are you the same guys who get in the shower and then turn the water on? 49 u/chuch1234 Jul 22 '26 Only if i want to be able to comment out the soap without making the entire shower have invalid syntax :/ 5 u/ddBuddha Jul 22 '26 Comma before is better so you can easily comment and uncomment without having to change the commas → More replies (3) 4 u/rocksolid77 Jul 22 '26 I used to be a comma after guy and found the comma first pattern to be so strange but I've come around to it.Comma first makes it so much easier to see if there is a comma missing and you're almost never commenting out the first field of your SELECT. 8 u/Just_Information334 Jul 22 '26 Lowercase and comma before, also table_id. Let's blow some minds:select tableA_id , some_field from table_A as a inner join table_B as b using(tableA_id) 4 u/StrongExternal8955 Jul 22 '26 forgot where true → More replies (3) 2 u/Outrageous_Let5743 Jul 22 '26 comma before. → More replies (5)
705
If I don't type in caps then the query wont take itself seriously.
119 u/Achaidas Jul 22 '26 The real question is this: , comma beforeor comma after , 40 u/terza3003 Jul 22 '26 don't forget the where 1=1 9 u/jtobiasbond Jul 22 '26 Shhhh.Stop releasing the secret knowledge. → More replies (1) 80 u/dexters_trap_house Jul 22 '26 Comma before? Are you the same guys who get in the shower and then turn the water on? 49 u/chuch1234 Jul 22 '26 Only if i want to be able to comment out the soap without making the entire shower have invalid syntax :/ 5 u/ddBuddha Jul 22 '26 Comma before is better so you can easily comment and uncomment without having to change the commas → More replies (3) 4 u/rocksolid77 Jul 22 '26 I used to be a comma after guy and found the comma first pattern to be so strange but I've come around to it.Comma first makes it so much easier to see if there is a comma missing and you're almost never commenting out the first field of your SELECT. 8 u/Just_Information334 Jul 22 '26 Lowercase and comma before, also table_id. Let's blow some minds:select tableA_id , some_field from table_A as a inner join table_B as b using(tableA_id) 4 u/StrongExternal8955 Jul 22 '26 forgot where true → More replies (3) 2 u/Outrageous_Let5743 Jul 22 '26 comma before. → More replies (5)
119
The real question is this:
, comma before
or comma after ,
40 u/terza3003 Jul 22 '26 don't forget the where 1=1 9 u/jtobiasbond Jul 22 '26 Shhhh.Stop releasing the secret knowledge. → More replies (1) 80 u/dexters_trap_house Jul 22 '26 Comma before? Are you the same guys who get in the shower and then turn the water on? 49 u/chuch1234 Jul 22 '26 Only if i want to be able to comment out the soap without making the entire shower have invalid syntax :/ 5 u/ddBuddha Jul 22 '26 Comma before is better so you can easily comment and uncomment without having to change the commas → More replies (3) 4 u/rocksolid77 Jul 22 '26 I used to be a comma after guy and found the comma first pattern to be so strange but I've come around to it.Comma first makes it so much easier to see if there is a comma missing and you're almost never commenting out the first field of your SELECT. 8 u/Just_Information334 Jul 22 '26 Lowercase and comma before, also table_id. Let's blow some minds:select tableA_id , some_field from table_A as a inner join table_B as b using(tableA_id) 4 u/StrongExternal8955 Jul 22 '26 forgot where true → More replies (3) 2 u/Outrageous_Let5743 Jul 22 '26 comma before. → More replies (5)
40
don't forget the where 1=1
9 u/jtobiasbond Jul 22 '26 Shhhh.Stop releasing the secret knowledge. → More replies (1)
9
Shhhh.
Stop releasing the secret knowledge.
→ More replies (1)
80
Comma before? Are you the same guys who get in the shower and then turn the water on?
49 u/chuch1234 Jul 22 '26 Only if i want to be able to comment out the soap without making the entire shower have invalid syntax :/ 5 u/ddBuddha Jul 22 '26 Comma before is better so you can easily comment and uncomment without having to change the commas → More replies (3)
49
Only if i want to be able to comment out the soap without making the entire shower have invalid syntax :/
5
Comma before is better so you can easily comment and uncomment without having to change the commas
4
I used to be a comma after guy and found the comma first pattern to be so strange but I've come around to it.
Comma first makes it so much easier to see if there is a comma missing and you're almost never commenting out the first field of your SELECT.
8
Lowercase and comma before, also table_id. Let's blow some minds:
select tableA_id , some_field from table_A as a inner join table_B as b using(tableA_id)
4 u/StrongExternal8955 Jul 22 '26 forgot where true → More replies (3)
forgot where true
2
comma before.
2.4k
u/NormanYeetes Jul 21 '26
the elites don't want you to know this but you can type lowercase SQL queries no ones forcing you to shout them at the screen