Slight flaw in the script, as if the column name contains a reserved keyword. Say for example the word "DELETE". In this case the column variable should be wrapped in back ticks (`) to escape this.
Good catch, I've corrected the flaw.
cool
BTW, welcome to the site! How did you find us?
Google Search
Good catch, I've corrected the flaw.