Mongodb integration
suggest changeSyntax
- db.collection.insertOne(document, options(w, wtimeout, j, serializeFuntions, forceServerObjectId, bypassDocumentValidation), callback)
- db.collection.insertMany([documents], options(w, wtimeout, j, serializeFuntions, forceServerObjectId, bypassDocumentValidation), callback)
- db.collection.find(query)
- db.collection.updateOne(filter, update, options(upsert, w, wtimeout, j, bypassDocumentValidation), callback)
- db.collection.updateMany(filter, update, options(upsert, w, wtimeout, j), callback)
- db.collection.deleteOne(filter, options(upsert, w, wtimeout, j), callback)
- db.collection.deleteMany(filter, options(upsert, w, wtimeout, j), callback)
Parameters
Parameter | Details | —— | —— | document | A javascript object representing a document| documents | An array of documents query | An object defining a search query filter | An object defining a search query callback| Function to be called when the operation is done options| (optional) Optional settings (default: null) w | (optional) The write concern wtimeout | (optional) The write concern timeout. (default: null) j | (optional) Specify a journal write concern (default: false)
|upsert| (optional) Update operation (default: false) | multi | (optional) Update one/all documents (default: false) | serializeFunctions | (optional) Serialize functions on any object (default: false) | forceServerObjectId | (optional) Force server to assign _id values instead of driver (default: false) | bypassDocumentValidation | (optional) Allow driver to bypass schema validation in MongoDB 3.2 or higher (default: false)