Thanks Christophe.


On Wed, Jul 2, 2014 at 6:37 PM, Christophe COEVOET <[email protected]> wrote:

> Le 02/07/2014 15:57, Nima Sadjadi a écrit :
>
>  Thanks a lot Christophe,
>> Is there any advantage and/or performance increase using QueryBuilder
>> instead of using dql directly? or this is just for developer convenience?
>>
>>  There is no real performance change (well, at level of
> micro-optimisations, providing the string directly in the source code will
> be faster than doing a building with concatenation, but this is totally
> negligeable compared to the query execution).
>
> the main advantage of the QueryBuilder is that you have an object-oriented
> builder, allowing to reuse your building logic (you can pass the builder to
> a method adding some filtering), while doing the same with DQL strings
> would require doing weird string replacements (and likely buggy).
>
>
> --
> Christophe | Stof
>
> --
> 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.
>

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