语法错误,可能是由于字符型当成数值型,或者相反
举例来说,如下面传入一个参数 myid ,且值为 "123"
在数据库表里, 你的 id 是 integer 类型, 则
select * from xx where id=${myid} -> ... where id=123 正确
select * from xx where id='${myid}' -> ... where id='123' 错误
如果你的id是 varchar,则, :
select * from xx where id='${myid}' -> where id='123' 正确
select * from xx where id=${myid} -> where id=123 错误
请仔细体会.