@@ -662,25 +662,22 @@ Cursors
662
662
-------
663
663
664
664
The :method:`find() <db.collection.find()>` method returns a
665
- :term:`cursor`; however, in the :program:`mongo` shell, if the result
666
- of the :method:`find() <db.collection.find()>` is not assigned to a
667
- variable, then the cursor is automatically iterated up to 20 times
668
- [#setShellBatchSize]_ to print the documents referenced by the cursor,
669
- as in the following example:
665
+ :term:`cursor` to the results ; however, in the :program:`mongo` shell,
666
+ if the returned cursor is not assigned to a variable, then the cursor
667
+ is automatically iterated up to 20 times [#setShellBatchSize]_ to print
668
+ up to the first 20 documents that match the query, as in the following
669
+ example:
670
670
671
671
.. code-block:: javascript
672
672
673
673
db.inventory.find( { type: 'food' } );
674
674
675
- This operation will iterate the cursor up to 20 times and print the
676
- first 20 documents referenced by the cursor.
677
-
678
- If the result of the :method:`find() <db.collection.find()>` is
679
- assigned to a variable:
675
+ When you assign the :method:`find() <db.collection.find()>` to a
676
+ variable:
680
677
681
678
- you can type the name of the cursor variable to iterate up to 20
682
- times [#setShellBatchSize]_ and print the documents referenced by the
683
- cursor, as in the following example:
679
+ times [#setShellBatchSize]_ and print the matching documents, as in
680
+ the following example:
684
681
685
682
.. code-block:: javascript
686
683
0 commit comments