[DOCS-376] Documentation for cloneCollection is incorrect Created: 06/Aug/12  Updated: 30/Oct/23  Resolved: 08/Aug/12

Status: Closed
Project: Documentation
Component/s: manual
Affects Version/s: None
Fix Version/s: Server_Docs_20231030

Type: Improvement Priority: Major - P3
Reporter: Andre de Frere Assignee: Bob Grabar
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
related to SERVER-6719 cloneCollection should allow parsing ... Closed
Participants:
Days since reply: 11 years, 28 weeks ago

 Description   

The documentation for the cloneCollection command (http://www.mongodb.org/display/DOCS/cloneCollection+Command) refers to <namespace> of the collection you are cloning. In usage however, you only specify the collection name. Specifying the fully qualified namespace for the collection will result in nothing being copied. This is because we prepend the current database name to the string given.

For example: db.cloneCollection("localhost:27017", "test.some_collection") will try and clone the collection "test.test.some_collection".



 Comments   
Comment by auto [ 08/Aug/12 ]

Author:

{u'date': u'2012-08-08T07:06:54-07:00', u'email': u'samk@10gen.com', u'name': u'Sam Kleinman'}

Message: merge: DOCS-376 clone collection command
Branch: master
https://github.com/mongodb/docs/commit/079ac75c3145a7cb528669d5111c5eefe3f03971

Comment by Bob Grabar [ 08/Aug/12 ]

Ran the test. The existing documents in the collection were not dropped. No change is needed to the docs.

Generated at Thu Feb 08 07:38:33 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.