被坑了两次,记录加深记忆
oracle :
select * from table_name where 1=1
<#if secondName?has_content>
and second_name like '%'||:secondName||'%'
</#if>
mysql:
select * from table_name where 1=1
<#if secondName?has_content>
and second_name like concat('%', :second_name ,'%')
</#if>
以上就是mysql oracle sql like模糊查询的条件拼接的详细内容,更多关于mysql oracle sql like模糊查询的条件拼接的资料请关注九品源码其它相关文章!