-
Type: Improvement
-
Resolution: Won't Fix
-
Priority: Minor - P4
-
None
-
Affects Version/s: 5.0.0
-
Component/s: Catalog
-
None
-
Execution Team 2021-12-27, Execution Team 2022-01-10, Execution Team 2022-01-24, Execution Team 2022-02-07, Execution Team 2022-03-07, Execution Team 2022-04-18, Execution Team 2022-05-30
The dropDatabase command returns
{ "ok" : 1}
even when dropping a database that does not exist.
Changing the ok result would be a significant breaking change, but it would be helpful to return some detail to confirm whether the command succeeded AND a database was dropped.
The drop command returns an errmsg when attempting to drop a non-existent collection:
> db.runCommand({'drop': 'foo'}) { "ok" : 0, "errmsg" : "ns not found", "code" : 26, "codeName" : "NamespaceNotFound" }
- is related to
-
SERVER-55145 Make dropping a nonexistent database a noop
- Closed