D
17

Debugged my first real SQL query after 3 hours

Spent like 3 hours last night trying to figure out why my JOIN was returning null values. Turned out I was referencing the wrong column name in the ON clause. I mispelled 'customer_id' as 'cust_id' and the table didn't even have that column. Learned to double-check my schema first before guessing. Has anyone else wasted an afternoon on a tiny typo like this?
2 comments

Log in to join the discussion

Log In
2 Comments
hayden587
hayden58720d ago
Wait, you wasted 3 hours over "cust_id" vs "customer_id"? That's brutal man. I would've been so mad when I finally spotted it.
5
miller.avery
Eh, 3 hours is annoying but that's just how coding goes sometimes. Not exactly the end of the world.
4