20.09.2012, 14:03
Vince has posted a nice thread, but to put it in short: you put an accent to the column or table name if you are not sure if it is a mysql keyword (or reserved word). These are words that you put into your query to get the result you want: SELECT, IN, IS, NOT, WHERE, HAVING, etc. If you do want these as a table name (which I had in a project once, which were IS-parts) you have to 'escape' the table names with those back ticks. So:
SELECT * FROM `IS` WHERE 1=1
SELECT * FROM IS WHERE 1=1 will give an error.
SELECT * FROM `IS` WHERE 1=1
SELECT * FROM IS WHERE 1=1 will give an error.