I'm working on a Symfony app that uses Doctrine as the ORM. I want to run a query with an WHERE foo IN (bar)
clause, and I'm adding the IN bit like so:
$query->andWhereIn('p.foo', $bar);
where $bar is an array of id numbers. Browsing the docs and trying out a few combinations, I was unable to make Doctrine treat the parameter I'm passing there as a named parameter.
As a result, I'm forced to use positional parameters for the rest of the query, too, as you can't mix the two. What, if anything, am I missing?