604
Little Timmy Tables (programming.dev)
you are viewing a single comment's thread
view the rest of the comments
[-] NullPointerException@lemmy.ca 57 points 6 hours ago

Why would Santa need two separate tables for this?

[-] joyjoy@lemmy.zip 47 points 6 hours ago* (last edited 6 hours ago)

I would make two separate views. 

CREATE VIEW NiceList AS
 SELECT * FROM Children
  WHERE behavior = 'nice' 
   AND parent.income > 40000; 
CREATE VIEW NaughtyList AS
 SELECT * FROM Children
  WHERE behavior = 'naughty'; 
[-] NullPointerException@lemmy.ca 31 points 6 hours ago

The income is a nice touch.

load more comments (7 replies)
load more comments (11 replies)
this post was submitted on 16 Dec 2025
604 points (99.2% liked)

Programmer Humor

27882 readers
824 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