Details
Description
It looks like the necessary ingredients to repro are:
- a collation
- multiple point ranges
- the point ranges are indexed in descending order
- more than one index can satisfy the query
- the query asks for a sort within each point range
var coll = db.foo; |
coll.drop();
|
db.createCollection(coll.getName(), {collation: {locale: 'fr'}}); |
coll.createIndex({x: -1});
|
coll.createIndex({x: -1, y: 1});
|
|
coll.find({x: {$in: [2, 5]}}).sort({y: 1}).toArray(); |