- Reference >
- Operators >
- Query and Projection Operators >
- $comment
$comment¶
On this page
Definition¶
Behavior¶
You can use the $comment
with any expression taking a query
predicate, such as the query predicate in
db.collection.update()
or in the $match
stage of
the aggregation pipeline.
For an example, see Attach a Comment to an Aggregation Expression.