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
[–] expr@programming.dev 6 points 15 hours ago

No variables, no functions

Every major SQL implementation includes both of those things. Of course, it's rarely needed or desirable if you know how to properly write SQL.

"So why can't you do that with expressions?"

You can alias expressions.

And then you try put a MAX in a where and it won't let you because you gotta pull all the maxes out in their own query, make a table, join them in, and use them like a filter...

Wtf are you talking about? For one, filtering by the output of an aggregate is what the HAVING clause is for. But even if that didn't exist, you could just use a subquery instead. You don't need to make table...

Tbh it just sounds like you don't know SQL very well. Which is fine, but doesn't make for a very compelling criticism. SQL does have warts (even though it's great overall), but none of what you described are real problems.