被坑了兩次,記錄加深記憶 oracle : select * from table_name where 1=1 <#if secondName?? && secondName?has_content> and second_name like '%'||:secondName||'%' </#if ...
被坑了兩次,記錄加深記憶
oracle :
select * from table_name where 1=1
<#if secondName?? && secondName?has_content>
and second_name like '%'||:secondName||'%'
</#if>
mysql:
select * from table_name where 1=1
<#if secondName?? && secondName?has_content>
and second_name like concat('%', :second_name ,'%')
</#if>