Reputation: 11
this is the structure of my table
[
"_id" :
"rating" : ,
"user_id" :
"review_id" :
"user_url" :
"content" : ,
"review_date" :
"bus_url" :
"type" : ,
"categories" : [
]
How would I count the number of user_ids who occur more than once. How would I do this?
Upvotes: 0
Views: 199
Reputation: 64613
You need to use $group
operator, more on it:
http://docs.mongodb.org/manual/reference/aggregation/group/
Upvotes: 1