<select id="getCount" resultType="int" parameterType="VmBigDataScreen">
select count(1) from vm_big_data_screen
<where>
<if test="screenname != null and screenname != ''">
and screenName like CONCAT('%',#{screenname},'%')
</if>
<if test="status != null and status != '' ">
and status = #{status,jdbcType=INTEGER}
</if>
</where>
</select>
<if test="status != null ">
and status = #{status,jdbcType=INTEGER}
</if>
当参数是Integer类型的时候,默认为空字符串。status != ' '
所以不要status != ' '写这个条件