unordered {
for $answer in collection("answers")
where $answer.score ge 4
count $c
where $c le 2
return $answer
}
Results:
{
"_id" : "511C7C5D9A277C22D13880C3",
"question_id" : 37823,
"answer_id" : 37841,
"creation_date" : "2008-09-01T12:14:38",
"last_activity_date" : "2008-09-01T12:14:38",
"score" : 7,
"is_accepted" : false,
"owner" : {
"user_id" : 2562,
"display_name" : "Ubiguchi",
"reputation" : 1871,
"user_type" : "registered",
"profile_image" : "http://www.gravatar.com/avatar/00b87
a917ec763c0c051dc6b8c06f402?d=identicon&r=PG",
"link" : "http://stackoverflow.com/users/2562/ubiguchi"
}
}
{
"_id" : "511C7C5D9A277C22D13880C4",
"question_id" : 37823,
"answer_id" : 37844,
"creation_date" : "2008-09-01T12:16:40",
"last_activity_date" : "2008-09-01T12:16:40",
"score" : 4,
"is_accepted" : false,
"owner" : {
"user_id" : 2974,
"display_name" : "Rob Wells",
"reputation" : 17543,
"user_type" : "registered",
"profile_image" : "http://www.gravatar.com/avatar/87692
81d99f8fe9c208fd6a926c383d1?d=identicon&r=PG",
"link" : "http://stackoverflow.com/users/2974/rob-wells
",
"accept_rate" : 94
}
}