Wernfried
My feedback
23 results found
-
1 vote
An error occurred while saving the comment -
3 votesWernfried supported this idea ·
-
5 votes
An error occurred while saving the comment Wernfried commentedCan be done with a single command:
db.exists() -> db.adminCommand( { listDatabases: 1 , filter: { name: 'db' } } ).databases.length > 0
and
collections.exists() -> db.getCollectionNames().includes('collections')
Most of these terms are deprecated and exist only for backward compatibility. For example 'db.isMaster()' is already replaced by 'db.hello()isWritablePrimary' or 'slaveDelay' became 'secondaryDelaySecs'