Answer the question
In order to leave comments, you need to log in
mongodb indexes?
What indexes should be for such a query?
db.foo.find({
$or : [ { a : 1 } , { b : 2 } ],
c: {$lte: 3}
}).sort( { c : -1 } )
Answer the question
In order to leave comments, you need to log in
> Whether indexes on many fields
have in general sense, if only on these fields there is a search. Example db.user.find({city:'Moscow', sex:0, age:18})
building a composite index on the fields city,sex,age
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question