@@ -27,10 +27,10 @@ cloneCollection
27
27
28
28
.. code-block:: javascript
29
29
30
- { cloneCollection: "users", from: "db .example.net:27017", query: { active: true }, copyIndexes: false }
30
+ { cloneCollection: "users.profiles ", from: "mongodb .example.net:27017", query: { active: true }, copyIndexes: false }
31
31
32
- This operation copies the "users" collection from the current
33
- database on the server at ``db .example.net``. The operation only
32
+ This operation copies the ``profiles`` collection from the
33
+ ``users`` database on the server at ``mongodb .example.net``. The operation only
34
34
copies documents that satisfy the query ``{ active: true }`` and
35
35
does not copy indexes. :dbcommand:`cloneCollection` copies indexes
36
36
by default, but you can disable this behavior by setting ``{
@@ -39,6 +39,6 @@ cloneCollection
39
39
40
40
:dbcommand:`cloneCollection` creates a collection on the current
41
41
database with the same name as the origin collection. If, in the
42
- above example, the ``users`` collection already exists, then
43
- MongoDB appends documents in the remote collection to the
44
- destination collection.
42
+ above example, the ``users`` collection already exists in the local
43
+ database, then MongoDB appends documents in the remote collection
44
+ to the destination collection.
0 commit comments