http://blog.csdn.net/responsecool/article/details/40189797
<!-- oracle -->
<!--
测试:没通过,不知道什么原因-->
<select id="searchUserBySearchName" parameterType="java.lang.String" resultType="com.urm.entity.User"> select * from t_user where user_name like CONCAT('%',#{search_name},'%') </select>

<!-- 或者  成功-->
<select id="searchUserBySearchName" parameterType="java.lang.String" resultType="com.urm.entity.User">
  select * from t_user where user_name like '%'||#{search_name}||'%' 
</select>

<!-- mysql -->
<select id="searchUserBySearchName" parameterType="java.lang.String" resultType="com.urm.entity.User">
  select * from t_user where user_name like CONCAT('%',#{search_name},'%')
</select>
  
<!-- sql server -->
<select id="searchUserBySearchName" parameterType="java.lang.String" resultType="com.urm.entity.User">
  select * from t_user where user_name like '%'+#{search_name}+'%'
</select>

<!-- db2 -->
<select id="searchUserBySearchName" parameterType="java.lang.String" resultType="com.urm.entity.User">
  select * from t_user where user_name like CONCAT('%',#{search_name},'%')  
</select>
<!-- 或者 -->
<select id="searchUserBySearchName" parameterType="java.lang.String" resultType="com.urm.entity.User">
  select * from t_user where user_name like '%'||#{search_name}||'%' 
</select>