Document & collection
MongoDB stores JSON-like documents (BSON) in collections within databases. Schema-flexible; no fixed columns. Documents can vary in structure.
use shop; db.users.insertOne({name:'a',age:30})
Databases · 10 sections
Document model, aggregation, indexing, and the NoSQL interview essentials.
MongoDB stores JSON-like documents (BSON) in collections within databases. Schema-flexible; no fixed columns. Documents can vary in structure.
use shop; db.users.insertOne({name:'a',age:30})
BSON is binary JSON with extra types (Date, ObjectId, Decimal128, Binary). More efficient to parse/scan; supports richer types.
Every document has _id (default ObjectId). Must be unique within collection. Drives primary key index (_id_).
_id: ObjectId('...')
127 more cards in this sheet
Unlock the Backend, Databases & AI bundle — ₹399
One-time payment. Unlocks this sheet and 14 other sheets in the bundle, plus a typeset PDF of each.
Unlock the bundle See all bundles
Or get all 76 sheets for ₹999 — one payment, every future sheet included.
What's new and the interview questions people are actually getting asked. No spam.