On this page
db.collection.drop()
在本页面
Definition
db.collection.drop()的格式为:
db.collection.drop()
db.collection.drop()不接受任何参数,如果使用任何参数调用都会产生错误。
返回: | true 成功删除收藏集时。false 当删除的集合不存在时。 |
---|
Behavior
此方法获得对受影响的数据库的写锁定,并将阻止其他操作,直到完成为止。
Example
以下操作将students
集合删除到当前数据库中。
db.students.drop()