| |
read source history
= getName() =
----
[[MongoDB Driver Function Reference]]
Gets the current database name.
More information can be found in the corresponding entry of the [[https://docs.mongodb.com/manual/reference/method/db.getName/index.html|MongoDB Manual]].
[[[@cG
db.getName()
]]]
**Return Value**
[[[@w
Returns a result set (cursor) containing the database name string value.
]]]
**Example**
[[[@cw
db.getName();
]]]
Returns the database name.
----
[[Main|home]] | [[MongoDB Driver Function Reference]] | [[MongoDB Driver]]
|