diff --git a/docs/en/reference/query-builder.rst b/docs/en/reference/query-builder.rst index 6b868c653..17638305a 100644 --- a/docs/en/reference/query-builder.rst +++ b/docs/en/reference/query-builder.rst @@ -499,6 +499,24 @@ complete list of supported helper methods available: public function countDistinct($x); // Returns Expr\Func } +Adding a Criteria to a Query +^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +You can also add a :ref:`Criteria ` to a QueryBuilder by +using ``addCriteria``: + +.. code-block:: php + + orderBy(['firstName', 'ASC']); + + // $qb instanceof QueryBuilder + $qb->addCriteria($criteria); + // then execute your query like normal Low Level API ^^^^^^^^^^^^^ diff --git a/docs/en/reference/working-with-associations.rst b/docs/en/reference/working-with-associations.rst index 16afcfd77..df7dd5955 100644 --- a/docs/en/reference/working-with-associations.rst +++ b/docs/en/reference/working-with-associations.rst @@ -616,11 +616,11 @@ address reference. When flush is called not only are the references removed but both the old standing data and the one address entity are also deleted from the database. +.. _filtering-collections: + Filtering Collections --------------------- -.. filtering-collections: - Collections have a filtering API that allows to slice parts of data from a collection. If the collection has not been loaded from the database yet, the filtering API can work on the SQL level to make optimized access to