I try to call collection.bulkWrite() in MongoDB stitch functions, but I get an error - “bulkWrite is not a function”. Is it possible to use bulkWrite() in MongoDB stitch functions?
Here is my stitch function - and I made it “run as a system”:
exports = function(arg){
var collection = context.services.get("mongodb-atlas").db("testDATABASE").collection("allSkuTable");
return collection.bulkWrite(some_paramets_inside);
};
What is the proper way to call bulkWrite() if it is even possible?