Monday 1 May 2017

Multiple insertion in mysql database, You have an error in your SQL syntax; check the manual that corresponds to your MySQL

I want to insert multiple record at the same time in the database and for that here is my sql instruction :

insert into tabo (fee,doo,ple,idur) values (?,?,?,?),(?,?,?,?),(?,?,?,?),(?,?,?,?) ON duplicate key update tabo.doo=values(doo),tabo.fee=values(fee);

Whe I am executing it, it is bringing this error:

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '?,?,?,?),(?,?,?,?),(?,?,?,?),(?,?,?,?) ON duplicate key update tabo.doo=values(doo),tabo.fee=values(fee);

I am not able to know where exactly I have an error. I need help to know what is wrong with my query.



via aidonsnous

No comments:

Post a Comment