Skip to content

Commit 84bad6d

Browse files
committed
NR PR fixes 1
1 parent 91c1bf6 commit 84bad6d

File tree

1 file changed

+28
-28
lines changed

1 file changed

+28
-28
lines changed

docs/query-builder.txt

Lines changed: 28 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -66,8 +66,8 @@ The following example shows the syntax of a query builder call:
6666

6767
This guide provides examples of the following types of query builder operations:
6868

69-
- :ref:`laravel-options-query-builder`
7069
- :ref:`laravel-retrieve-query-builder`
70+
- :ref:`laravel-options-query-builder`
7171
- :ref:`laravel-modify-results-query-builder`
7272
- :ref:`laravel-mongodb-read-query-builder`
7373
- :ref:`laravel-mongodb-write-query-builder`
@@ -86,33 +86,6 @@ of the Quick Start.
8686
To perform read and write operations by using the query builder, import the
8787
``Illuminate\Support\Facades\DB`` facade and compose your query.
8888

89-
.. _laravel-options-query-builder:
90-
91-
Set Query-Level Options
92-
-----------------------
93-
94-
You can modify the way that the {+odm-short+} performs queries by
95-
setting options on the query builder. You can pass an array of options
96-
to the ``options()`` query builder method to specify options for the
97-
query.
98-
99-
The following code demonstrates how to attach a comment to
100-
a query:
101-
102-
.. literalinclude:: /includes/query-builder/QueryBuilderTest.php
103-
:language: php
104-
:dedent:
105-
:start-after: begin options
106-
:end-before: end options
107-
108-
The query builder accepts the same options that you can set for
109-
the :phpmethod:`find() <phpmethod.MongoDB\\Collection::find()>` method in the
110-
{+php-library+}. Some of the options to modify query results, such as
111-
``skip``, ``sort``, and ``limit``, are settable directly as query
112-
builder methods and are described in the
113-
:ref:`laravel-modify-results-query-builder` section of this guide. We
114-
recommend that you use these methods instead of passing them as options.
115-
11689
.. _laravel-retrieve-query-builder:
11790

11891
Retrieve Matching Documents
@@ -638,6 +611,33 @@ value of ``imdb.rating`` of those matches by using the
638611
:start-after: begin aggregation with filter
639612
:end-before: end aggregation with filter
640613

614+
.. _laravel-options-query-builder:
615+
616+
Set Query-Level Options
617+
-----------------------
618+
619+
You can modify the way that the {+odm-short+} performs operations by
620+
setting options on the query builder. You can pass an array of options
621+
to the ``options()`` query builder method to specify options for the
622+
query.
623+
624+
The following code demonstrates how to attach a comment to
625+
a query:
626+
627+
.. literalinclude:: /includes/query-builder/QueryBuilderTest.php
628+
:language: php
629+
:dedent:
630+
:start-after: begin options
631+
:end-before: end options
632+
633+
The query builder accepts the same options that you can set for
634+
the :phpmethod:`find() <phpmethod.MongoDB\\Collection::find()>` method in the
635+
{+php-library+}. Some of the options to modify query results, such as
636+
``skip``, ``sort``, and ``limit``, are settable directly as query
637+
builder methods and are described in the
638+
:ref:`laravel-modify-results-query-builder` section of this guide. We
639+
recommend that you use these methods instead of passing them as options.
640+
641641
.. _laravel-modify-results-query-builder:
642642

643643
Modify Query Results

0 commit comments

Comments
 (0)