MongoDB 8 · Create, read, update, delete
Insert a document
Add one document to a collection.
db.users.insertOne({ name: "Ada", email: "[email protected]", age: 36 })
Official MongoDB 8 documentation
More create, read, update, delete commands
- Insert several documents
- Find all documents
- Find with a filter and projection
- Find one document
- Sort and paginate
- Count matching documents
All create, read, update, delete commands · MongoDB 8 cheatsheet