不要在查询文本中用引号将任何参数引起来!
->add('where', "c.owner = ?1 AND c.contact = u.id AND u.username LIKE '?2'")应该
->add('where', "c.owner = ?1 AND c.contact = u.id AND u.username LIKE ?2")
不要在查询文本中用引号将任何参数引起来!
->add('where', "c.owner = ?1 AND c.contact = u.id AND u.username LIKE '?2'")应该
->add('where', "c.owner = ?1 AND c.contact = u.id AND u.username LIKE ?2")