-
Notifications
You must be signed in to change notification settings - Fork 4.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[错误报告]: 标签前后的静态sql的换行符没了,标签前后的两行被合并到了一行,导致执行报错 #6704
Comments
mybatis/mybatis-3#3349 和这个有关吧,建议你换个方式写注释比如原生xml支持的注释格式 |
我看了下代码和提交记录,解析xml去除换行符是mybatis-plus实现的,https://github.com/baomidou/mybatis-plus/issues/6187,这个去除换行符的功能是否可以根据配置决定呢 |
那你debug看 |
执行mapper的查询方法,没有看到调用这个,这个方法会在什么情况下调用吗 |
没地方调用 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
确认
当前程序版本
3.5.10.1
问题描述
标签前后的静态sql的换行符没了,标签前后的两行被合并到了一行。
比如xml中sql如下
条件A不满足时,最后的sql合并成了两行
后面的
and #{field3} > 0
也被当成了注释,但是生成的预编译绑定参数又会多一个#{filed3},导致绑定参数时就因为索引溢出报错了详细堆栈日志
The text was updated successfully, but these errors were encountered: