This is a very simple question about the Doctrine. How to avoid single quotes?
For example, the title should be escaped since it contains one quote:
$query = $this->entityManager-> createQuery("SELECT p from \RTH\Entity\Prod p JOIN p.prodns ps JOIN ps.events e WHERE p.title = '" . $title . "'");
Is there a way to do this in Doctrine 2?
sql mysql doctrine2
Abs
source share