On 4 August 2014 13:46, naitsirch <[email protected]> wrote:

> The second DQL query is invalid, as you are fetch-joining and hydrating a
>> subset of the actual association.
>>
>
> Is it documented anywhere?
>
>>
I don't really know that, but if it isn't, then it should be added to the
"DQL" chapter.

That is a logical mistake, and doctrine can't detect it nor can support it.
>>
>
> I think Doctrine can detect it. Well, its not trivial, but doctrine knows
> the references and can see that there are conditions for the fetch-joined
> associations, which could limit the results.
>

It can probably be done in an AST walker, but what if the user really wants
that filtering to be applied? A hint can be added to allow such operations,
yes, but then we'd break BC quite badly.

Marco Pivetta

http://twitter.com/Ocramius

http://ocramius.github.com/

-- 
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.

Reply via email to