I want to migrate a large collection with millions of documents in a MongoDb collection.
The change itself is simple, i want to assign an empty array to a sub-document field that is null
db .collection('largeCollectionWithMillionsOfDocuments') .updateMany({ 'status.all': { $type: 10 } }, { $set: { 'status.all': [] } }, { upsert: false })
Are there any limits to number of documents that can be handled by updateMany in MongoDb?