update-many
Update multiple documents in a MongoDB collection using specified filter criteria. Apply modifications with an update document and optionally insert new documents if no matches exist.
Instructions
Updates all documents that match the specified filter for a collection
Input Schema
Name | Required | Description | Default |
---|---|---|---|
collection | Yes | Collection name | |
database | Yes | Database name | |
filter | No | The selection criteria for the update, matching the syntax of the filter argument of db.collection.updateOne() | |
update | Yes | An update document describing the modifications to apply using update operator expressions | |
upsert | No | Controls whether to insert a new document if no documents match the filter |