Given the following MySQL structure
the following models:
and using the following DQL:
will result in the following sql query:
there are 2 comma's between "f0_.fooReference AS fooReference1" and "b1_.barID AS barID2" resulting in an invalid query.
The first line of the walkSelectClause function in Doctrine/ORM/Query/SqlWalker.php will implode the result of the array_map.
But you receive an empty result from processing the data for the selectExpression "fb" explaining why you got the extra comma.
This worked in a previous version when 2.1 was still in development.