mybatis中mapping文件like查询方式

方式1:

select * from person where name like "%"#{name}"%"

方式2:

select * from person where name like '%'||#{name}||'%'

方式3:

select * from person where name like '%${name}%'

方式4:

select * from person where name like CONCAT('%',#{name},'%')

posted @ 2016-03-25 18:52  java攻城狮  阅读(838)  评论(1编辑  收藏  举报