> c.drop() true > c.save({c:1}) > c.save({c:'a'}) > c.save({c:null}) > c.save({}) > c.find({c:{$all:[]}}) // seems to match nothing > c.find({c:null}) // matches as expected { "_id" : ObjectId("4eec1e9942f62c7f2f5eedee"), "c" : null } { "_id" : ObjectId("4eec1e9d42f62c7f2f5eedef") } > c.find({c:{$all:[null]}}) // seems to match everything { "_id" : ObjectId("4eec1e9542f62c7f2f5eedec"), "c" : 1 } { "_id" : ObjectId("4eec1e9742f62c7f2f5eeded"), "c" : "a" } { "_id" : ObjectId("4eec1e9942f62c7f2f5eedee"), "c" : null } { "_id" : ObjectId("4eec1e9d42f62c7f2f5eedef") } > c.find({c:{$all:[1]}}) { "_id" : ObjectId("4eec1e9542f62c7f2f5eedec"), "c" : 1 } > c.ensureIndex({c:1}) > c.find({c:{$all:[]}}) > c.find({c:null}) { "_id" : ObjectId("4eec1e9942f62c7f2f5eedee"), "c" : null } { "_id" : ObjectId("4eec1e9d42f62c7f2f5eedef") } > c.find({c:{$all:[null]}}) // now matches are bounded by index range { "_id" : ObjectId("4eec1e9942f62c7f2f5eedee"), "c" : null } { "_id" : ObjectId("4eec1e9d42f62c7f2f5eedef") } > c.find({c:{$all:[1]}}) { "_id" : ObjectId("4eec1e9542f62c7f2f5eedec"), "c" : 1 }
- is related to
-
SERVER-7388 Implement all query operators using MatchExpression
- Closed