-
Type: Bug
-
Resolution: Done
-
Priority: Major - P3
-
None
-
Affects Version/s: None
-
Component/s: Querying
-
Query
-
ALL
When the document in the collection contains an array:
{a: [1,10]}
and we run a non-equality query with a scalar operand, we see the following results:
{a: {$gt: 1}} -----> 1 document {a: {$lt: 1}} -----> 0 document {a: {$ne: 1}} -----> 0 document
> db.f.drop() true > db.f.save( {a:[1,10]} ) > db.f.find( {a:{$gt:1}} ) { "_id" : ObjectId("4cb5fdb359001b4d0429c9de"), "a" : [ 1, 10 ] } > db.f.find( {a:{$ne:1}} ) >
- is depended on by
-
SERVER-958 Range queries on arrays behave differently with indexes
- Closed
- is related to
-
SERVER-31876 $ne has inconsistent behavior
- Closed
- related to
-
SERVER-3596 type bracketing used for $not query indexing, but not matching
- Closed