我有:Symfony和DQL
public function findTodasLasCompras($usuario_id)
{
$em = $this->getEntityManager();
$dql = 'SELECT v, o, t
FROM OfertaBundle:Venta v
JOIN v.oferta o
JOIN o.tienda t
WHERE v.usuario = :id
ORDER BY v.fecha DESC';
$consulta = $em->createQuery($dql);
$consulta->setParameter('id', $usuario_id);
$result = $consulta->getResult();
return $consulta->getResult();
}
,當我執行與它的錯誤失敗:
ContextErrorException:注意:未定義指數:Cupon \ OfertaBundle \實體\ Oferta在C:\ WAMP \ www \ sympony \ vendor \ doctrine \ orm \ lib \ Doctrine \ ORM \ Internal \ Hydration \ ObjectHydrator.php line 477
in C:\ wamp \ www \ sympony \ vendor \ doctrine \ orm \ lib \ Doctrine \ ORM \ Internal \ Hydration \ ObjectHydrator.php第477行 位於ErrorHandler-> handle('8','未定義索引:Cupon \ OfertaBundle \ Entity \ Oferta',
help!請!謝謝