Skip to content

Commit

Permalink
second review
Browse files Browse the repository at this point in the history
  • Loading branch information
eltharin committed Aug 24, 2024
1 parent ce472bb commit 8be75b6
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions docs/en/reference/dql-doctrine-query-language.rst
Original file line number Diff line number Diff line change
Expand Up @@ -629,7 +629,7 @@ you can use named arguments or variadic arguments, add ``WithNamedArguments`` to
}
}
And then you can select the fields you want in the order you want :
And then you can select the fields you want in the order you want, and the ORM will try to match argument names with the selected field names :

.. code-block:: php
Expand All @@ -639,7 +639,7 @@ And then you can select the fields you want in the order you want :
// CustomerDTO => {name : 'SMITH', email: null, city: 'London', value: null}
you can also aliases column :
ORM will also look column aliases before columns names :

.. code-block:: php
Expand All @@ -648,7 +648,10 @@ you can also aliases column :
$users = $query->getResult(); // array of CustomerDTO
// CustomerDTO => {name : 'DOE', email: null, city: null, value: 'New York 10011'}
Be careful, if two fields have the same name/alias, second will erase first.
If you put an argument name empty (for functions) or not in constructor argument list, ORM will throw an error.

Using INDEX BY
~~~~~~~~~~~~~~

Expand Down

0 comments on commit 8be75b6

Please sign in to comment.