this post was submitted on 19 Nov 2025
328 points (92.9% liked)

Programmer Humor

27391 readers
1622 users here now

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

founded 2 years ago
MODERATORS
 
you are viewing a single comment's thread
view the rest of the comments
[–] jjjalljs@ttrpg.network 14 points 15 hours ago* (last edited 15 hours ago)

Personally I feel like SQL syntax is upside down, and things are used before they are defined.

SELECT 
a.id -- what the fuck is a?
, a.name
, b.city -- and b??
from users a -- oh 
join city b on a.id = b.user_id -- oh here's b

I'd expect it to instead be like

From users a
join city b on a.id = b.user_id
SELECT
a.id,
a.name,
b.city