BSON (Binary JSON) is MongoDB’s binary-encoded format for storing JSON-like documents. It supports types beyond standard JSON, including dates and binary data, so an application can persist more than JSON alone can represent. section 1.1 section 1.6
A BSON document consists of field-and-value pairs. Values can include strings, numbers, arrays, and nested documents; documents with different fields can coexist in a collection. Keeping related information together can reduce the reads needed to retrieve it. section 2.6.4 section 1.1
Listing 2.7 Displaying a single MongoDB document using findOne()
[primary] sample_training> use sample_training
already on db sample_training
[primary] sample_training> db.grades.findOne()
{
_id: ObjectId('56d5f7eb604eb380b0d8d8ce'),
student_id: 0,
scores: [
{ type: 'exam', score: 78.40446309504266 },
{ type: 'quiz', score: 73.36224783231339 },
{ type: 'homework', score: 46.980982486720535 },
{ type: 'homework', score: 76.67556138656222 }
],
class_id: 339
}
[primary] sample_training>
Run `db.grades.findOne()` in the `sample_training` database to inspect a document with an ObjectId `_id` and an array of assessment objects. The listing shows a document as displayed by the query, not its binary encoding. section 2.6.4
Keep document size in mind: a BSON document cannot exceed 16 MB. The limit prevents one document from consuming excessive RAM or transmission bandwidth. section 2.6.4

