AND (brand LIKE CONCAT('%', #{f.keyword}, '%') OR asin LIKE CONCAT('%', #{f.keyword}, '%')) AND country = #{f.country} AND gating_type = #{f.gatingType} AND status = #{f.status} AND source = #{f.source} UPDATE biz_brand_gating SET status = #{status}, disabled_at = IF(#{status} = 1, NULL, NOW()), updated_at = NOW() WHERE id = #{id}