You know the situation. You’re working on a project and when testing it you get an unexpected result or error message. That happens to me all the time but one such time last week took me ages to figure out what was going on.
I was using a simple sql statement to select records from a database but I’d called one of the fields in the table “From”. Obviously this will create problems when writing the simple sql statement and it caused me to get a MySQL error telling me to check my syntax.
I found out the hard way when doing something stupid in Javascript a few weeks ago as well.
Lesson learned:
Think before creating fields in a database!
As Homer would say…..DOH!