当前使用版本(必填,否则不予处理)
3.5.3.1
该问题是如何引起的?(确定最新版也有问题再提!!!)
调用baseMapper的selectCount方法 或者service中的count方法;
重现步骤(如果有就写完整)
正常生成,调用count方法拼接的sql有问题!
报错信息
SELECT COUNT( select 1 ) AS total FROM finance_bill WHERE xxxxx
Cause: java.sql.SQLSyntaxErrorException: 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 'select 1
) AS total FROM xxxx
WHERE (xxxxxxx = xxx' at line 2
; bad SQL grammar []; nested exception is java.sql.SQLSyntaxErrorException: 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 'select 1 ) AS total FROM XXX
Comment From: dpzain
笔误!