[SERVER-2144] Rename drop to dropCollection ? Created: 24/Nov/10  Updated: 12/Jul/16  Resolved: 24/Nov/10

Status: Closed
Project: Core Server
Component/s: Usability
Affects Version/s: None
Fix Version/s: 1.7.4

Type: Question Priority: Minor - P4
Reporter: Lucas Zamboulis Assignee: Unassigned
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Participants:

 Description   

Would it be possible to rename db.foo.drop() to db.foo.dropCollection() ? It is quite easy to confuse this on the shell, e.g. type db.foo.drop(

{x:1}

) instead of db.foo.remove(

{x:1}

).

If not, then at least db.foo.drop(

{x:1}

) should throw an exception rather than proceed to drop the collection, since most likely it has been confused with remove.



 Comments   
Comment by auto [ 24/Nov/10 ]

Author:

{'login': 'erh', 'name': 'Eliot Horowitz', 'email': 'eliot@10gen.com'}

Message: throw exception if drop() given an argument SERVER-2144
/mongodb/mongo/commit/cda009c77bdd1ef39e5001d003e2e4d0bd9142ad

Comment by Eliot Horowitz (Inactive) [ 24/Nov/10 ]

Did option #2
Don't think we want to rename.

Generated at Thu Feb 08 02:59:06 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.