See: https://coderwall.com/p/ibuybw
$em = $this->getEntityManager('db');
$qb = $em->createQueryBuilder();
$qb->select('e')
->from('ProjectMyBundle:Employee', 'e')
->where('e INSTANCE OF ProjectMyBundle:ChefPosition')
On Monday, 4 April 2011 12:48:18 UTC+10, Guilherme Blanco wrote:
>
> Hi,
>
> Please open a feature request for that on JIRA. I think it can be
> included for 2.1 =)
>
> Cheers,
>
> On Sun, Apr 3, 2011 at 11:29 PM, Patrik Votoček <[email protected]
> <javascript:>> wrote:
> > $qb->select('Entities\Node', 'n')->where("n.level = 1");
> > $classes = array();
> > foreach ($nodes as $class) {
> > $classes[] = "node INSTANCE OF " . $class;
> > }
> >
> > $qb->andWhere(call_user_func_array(array($qb->expr(), 'orx'),
> > $classes)));
> >
> > any one better solution?
> >
> > --
> > You received this message because you are subscribed to the Google
> Groups "doctrine-user" group.
> > To post to this group, send email to [email protected]
> <javascript:>.
> > To unsubscribe from this group, send email to
> [email protected] <javascript:>.
> > For more options, visit this group at
> http://groups.google.com/group/doctrine-user?hl=en.
> >
> >
>
> --
> Guilherme Blanco
> Mobile: +55 (16) 9215-8480
> MSN: [email protected] <javascript:>
> São Paulo - SP/Brazil
>
>
--
You received this message because you are subscribed to the Google Groups
"doctrine-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/doctrine-user.
For more options, visit https://groups.google.com/d/optout.