美文网首页
Mybatis开发中遇到的坑

Mybatis开发中遇到的坑

作者: 明丶夷 | 来源:发表于2019-06-14 17:10 被阅读0次

if标签 中的 and 问题:

通过 if 控制 动态sql 时,多个条件连接时要注意 and 的写法。必须是 小写的and大写的AND 不识别。
<if test="name1 !=null and name2 != null"> 是正确的;
<if test="name1 !=null AND name2 != null"> 是错误的

相关文章

网友评论

      本文标题:Mybatis开发中遇到的坑

      本文链接:https://www.haomeiwen.com/subject/mybpfctx.html