mongo count collections code example
Example 1: see number of documents in mongodb collection
db.collection.count()
Example 2: mongo count
db.collection.countDocuments( <query>, <options> )
Example 3: count collection mongodb
db.mycollection.count()