Mybatis动态SQL单一基础类型参数用if标签
Mybatis动态SQL单一基础类型参数用if标签时,test中应该用 _parameter,如:<select id="selectByName" resultMap="ResultMap" parameterType="java.lang.String" >
select * from table1
<if test="_parameter != null">
where _name = #{name}
</if>
</select>
页:
[1]