Is there a way to order this query by the length of the string contained in the Title field?
$query = $this->getEntityManager()
->createQuery('
SELECT b FROM AcmeTestBundle:Blog b
WHERE b.Title LIKE :title'
)->setParameter('title','%'.$title.'%');
ORDER BY b.Title.length() doesn’t seem to work.
Yes, just try: