Update operation
The update operation modifies a document record in a collection, based on a given query parameter and update.
FerretDB supports update operators, such as $set
and $setOnInsert
to update documents in a record.
At present, FerretDB currently supports the following update operators:
Operator name | Description |
---|---|
$set | Assigns the value for an updated field to the document. |
$setOnInsert | Specifies the value of a field when an update operation results in the addition of a document. However, there is no effect when it modifies an existing document. |
$unset | Removes a specific field from a document. |
$pop | In an array, this operator removes the first or last item. |