NPM Library: "mongodb": "3.1.4"
I get the following error, when trying to bulk insert a list of data:
Code:
db.collection('products').insertManyAsync(products, {ordered: false})
Error:
Invalid Operation, no operations specified
NPM Library: "mongodb": "3.1.4"
I get the following error, when trying to bulk insert a list of data:
Code:
db.collection('products').insertManyAsync(products, {ordered: false})
Error:
Share Improve this question asked Sep 5, 2018 at 7:38 Nick GrealyNick Grealy 26k9 gold badges111 silver badges126 bronze badgesInvalid Operation, no operations specified
1 Answer
Reset to default 8Simple solution (but I couldn't find it listed anywhere), it turns out the products
array was empty, which causes the error.