当前使用版本(必填,否则不予处理)

3.4.2

该问题是如何引起的?(确定最新版也有问题再提!!!)

自己在xml中写的sql语句 select o.id, o.add_time from litemall_order o left join litemall_user u on o.user_id = u.id left join litemall_order_goods og on o.id = og.order_id <where> <if test="query != null"> ${query} </if> </where> group by o.id <if test="orderByClause != null"> order by ${orderByClause} </if> 加多租户后 生成的sql SELECT o.id, o.add_time FROM litemall_order o LEFT JOIN litemall_user u ON o.user_id = u.id AND u.enterprise_id = 1 ON o.user_id = u.id LEFT JOIN litemall_order_goods og ON o.id = og.order_id AND og.enterprise_id = 1 ON o.id = og.order_id WHERE o.deleted = 0 AND og.deleted = 0 AND o.enterprise_id = 36 GROUP BY o.id ORDER BY o.add_time DESC, o.id DESC

重现步骤(如果有就写完整)

报错信息

sql异常

Comment From: miemieYaho

https://github.com/baomidou/mybatis-plus/commit/720e770761a7731294de685822590e63da210b14 无法复现

Comment From: cool-han

720e770 无法复现

https://github.com/baomidou/mybatis-plus/commit/22f628dbe32bb433b9dc14f1715979acf5714ee6 发现在3.4.3.4已经修复此问题