Navigation
This version of the manual is no longer supported.

db.getCollection()

db.getCollection(name)
Parameters:
  • name – The name of a collection.
Returns:

A collection.

Use this command to obtain a handle on a collection whose name might interact with the shell itself, including collections with names that begin with _ or mirror the database commands.