美文网首页
Mybatis中大于等于小于等于的写法

Mybatis中大于等于小于等于的写法

作者: FantJ | 来源:发表于2018-08-09 16:24 被阅读160次

方法一:对照表

原符号 < <= > >= & ' "
替换符号 &lt; &lt;= &gt; &gt;= &amp; &apos; &quot;

示例:

  <select id="selectCountNotRead" resultType="java.lang.Integer">
    select count(news_id)
    from ip_news
    where user_id = #{userId,jdbcType=VARCHAR}
    and (news_status + news_ignore) &lt; 1
  </select>

方法二:

大于等于:<![CDATA[ >= ]]>

小于等于:<![CDATA[ <= ]]>

相关文章

网友评论

      本文标题:Mybatis中大于等于小于等于的写法

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