I run explain on the following query:
db.explain().find({ site_id:1, dimensions:[], create_date: { $gte: new Date(1452603948196) } )
The result contains a 'filter' object over the dimensions field, while it should have filtered that field using the index, what does it mean ? isn't it a redundant stage?
{ "winningPlan" : {
"stage" : "FETCH",
"filter" : {
"dimensions" : {
"$eq" : [ ]
}
},
"inputStage" : {
"stage" : "IXSCAN",
"keyPattern" : {
"site_id" : 1,
"dimensions" : 1,
"create_date" : 1
}, }
as far as i understand it means that mongo filter the dimensions field again after it is scanning the index and fetch the documents into memory, is it correct?
thanks,