Is such a operation possible?
sample record:
{
_id: ObjectId("51d6be147483c58419000002"),
user: "ashok",
action: "login",
time: 1373027860,
details: {
user_entries: "blah..blah",
url: "web.domain.com"
}
}
Suppose, i want to group by url visited, for each user,
group by url where user = "ashok", limit 10.
I am using AlexBilbie library for MongoDB-Codeigniter (it doesnt have aggregation). so using plain php.
Still even if I could aggregate, how to distinct or limit it?
Any suggestion is welcome.
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…