@@ -205,27 +205,31 @@ in ``mongosh`` better align with the types used by the MongoDB Drivers.
205
205
Undefined Values
206
206
----------------
207
207
208
- The undefined BSON type is `deprecated <https://bsonspec.org/spec.html>`__ in
209
- :binary:`bin.mongosh`. If you insert a document with the undefined JS type in
210
- :binary:`bin. mongosh`, your deployment replaces the undefined value in your
208
+ The undefined BSON type is `deprecated <https://bsonspec.org/spec.html>`__.
209
+ If you try to insert a document with the undefined JS type in
210
+ `` mongosh` `, your deployment replaces the undefined value in your
211
211
document with the BSON null value. There is no supported way of inserting undefined
212
- values into your database using :binary:`bin. mongosh`.
212
+ values into your database using `` mongosh` `.
213
213
214
214
For example, consider running the following code to insert a document in
215
- :binary:`bin. mongosh`:
215
+ `` mongosh` `:
216
216
217
217
.. code-block:: javascript
218
218
219
219
db.people.insertOne( { name : "Sally", age : undefined } )
220
220
221
- When you run this code in :binary:`bin. mongosh`, the shell inserts
221
+ When you run this code in `` mongosh` `, the shell inserts
222
222
the following document:
223
223
224
224
.. code-block:: javascript
225
225
"copyable: false
226
226
227
227
{ name : "Sally", age : null }
228
228
229
+ ``mongosh`` represents any BSON undefined values stored using other tools, such as
230
+ the `Go Driver <https://www.mongodb.com/docs/drivers/go/current/>`__ or the
231
+ legacy ``mongo`` shell, as null.
232
+
229
233
Object Quoting Behavior
230
234
-----------------------
231
235
0 commit comments