This error comes when you have a column name from one of the mysql keyword, try to run your queries by putting all your column names in `` this
example: insert into test (`sno`, `order`, `category`, `samp`, `pamp`, `method`) values(1, 1, 'top', 30, 25, 'Total');
In this example column name order is a keyword in mysql, so i had to put that in `` quotes.