<select id="getRoughly" resultMap="BaseResultMap">
select net.*
from ${cmdb}.EPC_NETWORKS net,${cmdb}.EPC_SUBNETS sub
where
net.id=sub.NETWORK_ID and net.REGION_ID = '${regionId}'
<if test="name != null">
and net.NAME like
'%${name}%'
</if>
<if test="ip != null">
and sub.CIDR like '%${ip}%'
</if>
</select>
mybatis连表模糊查询
最新推荐文章于 2024-05-09 15:32:44 发布