http://www.cnblogs.com/littleCode/p/3727476.html oracle数据库: SELECT * FROM user WHERE name like CONCAT('%',#{name},'%') 或 SELECT * FROM user WHERE name like '%'||#{name}||'%' SQLServer数据库: SELECT * FROM user WHERE name like '%'+#{name}+'%' mysql数据库: S…
oracle数据库: SELECT * FROM user WHERE name like CONCAT('%',#{name},'%') 或 SELECT * FROM user WHERE name like '%'||#{name}||'%' SQLServer数据库: SELECT * FROM user WHERE name like '%'+#{name}+'%' mysql数据库: SELECT * FROM user WHERE name like CONCAT('%',#{na…
1 使用map <select id="selectRole" parameterType="map" resultType="RoleMap"> SELECT id, roleName, note FROM role WHERE roleName LIKE Concat('%',#{roleName},'%') and note like Concat('%',#{note},'%') </select> 在接口中如下定…