I originally started developing a ruby in rails with mysql 4. One of the table in my is called 'reads'. The wasn't a problem.
Recently my host upgraded to mysql 5, so I installed mysql5 on my development environment. 'reads' has now been added to the reserved word list. I now get the following error:
If I was writing the sql myself I would just quote the table name, which would get round the problem but I don't have this control when abstracting the sql using rails.Code:Mysql::Error: #42000You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'reads' at line 1: SHOW FIELDS FROM reads
Any way of getting round this without changing my table name?