在下面的 explain() 中,查看底部以查看Document.Record.l
where I comment的值1.7 ^ 308?
。
为什么这个值没有10
像我设置的那样设置l
在 1 到 9 之间?它设置为1.7 ^ 308从性能的角度来看,设置如此高的上限这一事实让我感到担忧。
> db.collection.find( {"Document.Record" : {$all : [ {$elemMatch: {n: "Name", v: "Kevin",
"l" : { "$gt" : 0 , "$lt" : 10}} }]}}, {_id : 1}).explain
()
{
"cursor" : "BtreeCursor Document.Record.n_1_Document.Record.v_1_Document.Record.l_1",
"isMultiKey" : true,
"n" : 2049,
"nscannedObjects" : 4706,
"nscanned" : 4706,
"nscannedObjectsAllPlans" : 4706,
"nscannedAllPlans" : 4706,
"scanAndOrder" : false,
"indexOnly" : false,
"nYields" : 0,
"nChunkSkips" : 0,
"millis" : 91,
"indexBounds" : {
"Document.Record.n" : [
[
"Name",
"Name"
]
],
"Document.Record.v" : [
[
"Kevin",
"Kevin"
]
],
"Document.Record.l" : [
[
0,
1.7976931348623157e+308 /* 1.7 ^ 308! */
]
]
},
"server" : "Doesn't Matter"
}
>