You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to mongodb-user
I'd like to know if getting amount of documents in collection
(collection.count()) is expensive
on large colelctions? In otherr words: does mongo keep tracks of this
number and can provide it instantly or does it perform something like
full scan or other calculations that can be slow when there is lot of
documents?
--
Maciej Dziardziel
Eliot Horowitz
unread,
Nov 27, 2009, 8:32:41 AM11/27/09
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to mongod...@googlegroups.com
Count with no filter is fast, we keep track of the number of objects
in a collection
If you specify a query, then it has to so the query
On Nov 27, 2009, at 7:52 AM, Maciej Dziardziel <fie...@gmail.com>
wrote: