Make the MongoDB docs better! We value your opinion. Share your feedback for a chance to win $100.
Click here >
Docs Menu
Docs Home
/ /

Logical Query Predicate Operators

Logical operators return data based on boolean logic (and, or, and nor).

Name
Description

$and

Joins query clauses with a logical AND and returns documents that match the conditions of all clauses.

Joins query clauses with a logical NOR and returns all documents that fail to match all clauses.

Inverts the effect of a query predicate and returns documents that do not match the query predicate.

Joins query clauses with a logical OR and returns all documents that match at least one clause.

Back

$polygon