Mybatis SQL map配置中出现小于号转义时,通过<![CDATA[查询条件]]>解决。
EXCEMPLE:
<select id="getComments"
parameterType="Pagination" resultType="CustomerComments">
SELECT *
FROM kk_customercomments
<if test="condition != null">
WHERE
true
<if test="condition.enddate != null">
and <![CDATA[COMMENTSDATE
<=
‘${condition.enddate}‘]]>
</if>
</if>
</select>
Mybatis sql map 小于号配置,布布扣,bubuko.com
原文:http://www.cnblogs.com/dylanw/p/3576175.html