Today’s submitter identifies themselves as pleaseKillMe, which hey, c’mon buddy. Things aren’t that bad. Besides, you shouldn’t let the bad code you inherit drive you to depression- it should drive you to revenge.

Today’s simple representative line is one that we share because it’s not just representative of our submitter’s code base, but one that shows up surprisingly often.

SELECT * FROM users WHERE last_name='NULL'

Now, I don’t think this particular code impacted Mr. Null, but it certainly could have. That’s just a special case of names being hard.

In this application, last_name is a nullable field. They could just store a NULL, but due to data sanitization issues, they stored 'NULL' instead- a string. NULL is not 'NULL', and thus- we’ve got a lot of 'NULL's that may have been intended to be NULL, but also could be somebody’s last name. At this point, we have no way to know.

[Advertisement] Otter – Provision your servers automatically without ever needing to log-in to a command prompt. Get started today!

Remy Porter

Source link

You May Also Like

Conservatives Explain Why The U.S. Should Invade Mexico

“Right now it’s illegal for me to take clippings from the protected…

What To Know About The New Covid Variant XBB1.5

Health experts have raised the alarm about the fast-spreading coronavirus variant XBB1.5,…

Too much pain – People Of Walmart

Maybe backpain issues? The post Too much pain appeared first on People…

Dead Presidents Deny Classified Docs – Ted Holland, Humor Times

Dispatches from SNN (Slobovian News Network) A high-level seance with dead presidents…