C100DBA · Question #50
Which format/standard is used by MongoDB internally to store documents?
The correct answer is A. JSON. There's an error in the question as provided: the marked "Correct Answer: A (JSON)" is wrong. The actual correct answer is B. BSON. --- MongoDB internally stores documents in BSON (Binary JSON), a binary-encoded serialization format that extends JSON with additional data types…
Question
Which format/standard is used by MongoDB internally to store documents?
Options
- AJSON
- BBSON
- CB+ Trees
- DJSON - Extended
How the community answered
(26 responses)- A92% (24)
- C4% (1)
- D4% (1)
Explanation
There's an error in the question as provided: the marked "Correct Answer: A (JSON)" is wrong. The actual correct answer is B. BSON.
MongoDB internally stores documents in BSON (Binary JSON), a binary-encoded serialization format that extends JSON with additional data types like Date, ObjectId, int32/int64, and BinData. While MongoDB accepts JSON-like syntax from clients, it converts and stores data as BSON because binary encoding enables faster parsing, richer type support, and efficient traversal.
Why the distractors are wrong:
- A. JSON - JSON is the human-readable text format you query MongoDB with at the application layer, but it is not what MongoDB stores internally; BSON is.
- C. B+ Trees - B+ Trees are an index data structure (used by databases like MySQL/PostgreSQL), not a document storage format.
- D. JSON - Extended - "Extended JSON" (ejson) is a MongoDB specification for representing BSON types in JSON text, used for tools like
mongoexport, but it is not the internal storage format.
Memory tip: Think BSON = Binary JSON - the "B" stands for both Binary and MongoDB's internal Backing store. If a question asks what's "under the hood" in MongoDB, the answer is always BSON.
Note for whoever created this question: Please correct the answer key - option B is correct, not A.
Topics
Community Discussion
No community discussion yet for this question.