sql mapper 里面 Integer 类型判断

<if test="isChoiceness != null and isChoiceness != -1">
AND sa.is_choiceness = #{isChoiceness}
</if>

isChoiceness 是一个Integer 类型的值,所以只能判断是否是null 和是否是 数字类型的值,不能判断为空字符串 isChoiceness != ''  
posted @ 2019-05-28 11:17  Sea_wxx  阅读(418)  评论(0编辑  收藏  举报