Skip to content

Commit 2dc4c6f

Browse files
author
Sam Kleinman
committed
merge: pull request with additional information about $or operator
2 parents 089108c + 3b56f7e commit 2dc4c6f

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

source/core/indexes.txt

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -796,3 +796,14 @@ Be aware of the following behaviors and limitations:
796796

797797
- Create indexes to support queries and other operations, but do not
798798
maintain indexes that your MongoDB instance cannot or will not use.
799+
800+
- For queries with the :operator:`$or` operator,
801+
each clause of an :operator:`$or` query executes in parallel, and
802+
can each use a different index.
803+
804+
- For queries that use the :method:`sort() <cursor.sort()>` method and
805+
use the :operator:`$or` operator, the query **cannot** use the
806+
indexes on the :operator:`$or` fields.
807+
808+
- ``2d`` :doc:`geospatial queries </core/geospatial-indexes>` do not
809+
support queries that use the :operator:`$or` operator.

0 commit comments

Comments
 (0)