this post was submitted on 22 Aug 2025
255 points (99.2% liked)

Programmer Humor

38035 readers
225 users here now

Post funny things about programming here! (Or just rant about your favourite programming language.)

Rules:

founded 6 years ago
MODERATORS
top 14 comments
sorted by: hot top controversial new old
[–] Warl0k3@lemmy.world 49 points 1 week ago (3 children)

I used to leave my name, personal cell # and an apology at the top of any of my dynamic SQL queries. I know what its going to be like, man, I wrote that shit. I'm so sorry.

[–] xthexder@l.sw0.com 26 points 1 week ago (1 children)

Bold move.. Hopefully you're not getting calls in 10 years when stuff breaks and you're at a different company

[–] Warl0k3@lemmy.world 21 points 1 week ago* (last edited 1 week ago) (1 children)

(Public sector, if this stuff goes down people don't get their heart meds so I don't overly mind the stale followup calls. Tho I'll be shocked if any of that code is still in use, most of it was being obsoleted even back when I still worked there)

[–] AdamEatsAss@lemmy.world 5 points 1 week ago

Plus then you can bill as an independent contractor.

[–] afk_strats@lemmy.world 13 points 1 week ago (1 children)

I wish I was working on your stuff back when I supported stinky 2008 T-SQL where everything was dynamic and sequential. I would have called you just for moral support

[–] Warl0k3@lemmy.world 8 points 1 week ago (1 children)

Comon over to Tsql 2022! Nothing has changed, except the AI is writing the dynamic SQL now so you don't have to! It's going great!

[–] afk_strats@lemmy.world 1 points 1 week ago

Just to be clear, I think T-SQL is fine and apparently they added some string agg function so you don't have to hack XML_agg so... Something improved. But stinky spaghetti SQL is unfixable

dynamic SQL. I remember those days. I once got criticized by colleagues for "breaking" a dynamic SQL search query - you know the one - because I realized that it wasn't building most of the query. I have no idea how it worked, but I made it put out actually valid SQL and it took forever. I forget if we rolled that back. We were using MS TFS, so probably not haha

[–] VeryVito@lemmy.ml 35 points 1 week ago (3 children)

I’ve written those same comments so many times over the years.

We all pretend our code doesn’t stink, but show me a developer who’s never left a a turd in a codebase, and I’ll show you someone who’s never been under a deadline.

[–] elvith@feddit.org 37 points 1 week ago
##############################
# ALL YE WHO ENTER HERE BE WARNED  
# THIS ISN'T MY FAULT, BUT $TOOL ONLY 
# ALLOWS THIS DIRTY WORKAROUND
#
# DO NOT CHANGE OR REFACTOR
# ANYTHING.
# 
# IF YOU NEED TO TOUCH THIS CODE
# INCREMENT THIS COUNTER AS A
# WARNING FOR THE NEXT POOR FUCK
# 
# TOTAL HOURS WASTED DEBUGGING
# 15
# TOTAL HOURS WASTED REFACTORING
# 8
# SUCCESSFUL CHANGES
# 0
##############################
[–] afk_strats@lemmy.world 7 points 1 week ago

Oh god this turned into a vent session

I think back of what I left behind. And I feel bad.

But then I feel better because I remember the reason I left was that we outgrew our processes and codebase and we desperately needed a restructure but i got no support in doing so.

I bitched for years that it was a continuity risk and a performance nightmare. But no. "Deliver more features. Add more junk for use cases that brought us no business value." Never consider governance or security. Never consider best practices. Just more.

I knew eventually something bad would happen and I would be thrown under the bus. So I split. It was a good decision.

But yeah. Seone inherited a lot turd code

[–] TrickDacy@lemmy.world 2 points 1 week ago

We all pretend our code doesn’t stink

For myself... Maybe for 5 solid minutes lol

[–] lowspeedchase@lemmy.dbzer0.com 12 points 1 week ago (1 children)

Too many companies living aboard the sunk-cost ship. Burn that trash to the ground.

[–] gerald_eliasweb@reddthat.com 12 points 1 week ago

General life advice: sometimes its more cost-effective to start over from scratch