So this is the culprit
mysql_query("UPDATE coordrating SET submissions = '2' WHERE rating = 2");
Now this works fine UNLESS I try to use the index (which is the index of my table) values.
So this doesn’t work:
mysql_query("UPDATE coordrating SET index = '2' WHERE rating = 2");
or
mysql_query("UPDATE coordrating SET submissions = '2' WHERE index = 2");
This is the screenshot of my database structure
http://imageshack.us/photo/my-images/694/problemmysql.png/
I’m completely baffled.
Try this way:
Backquotes are used to delimit table or field names, because sometimes table or fieldname can match MySQL operator.