Explain() not giving same info

using, command line, created index on m201.people last_name, first_name. ran this query: db.people.find({“last_name”:“Bailey”}).explain(). the explain does not give me “executionStats” section…what am I missing??

db.people.find({“last_name”:“Bailey”}).explain()
{
“queryPlanner” : {
“plannerVersion” : 1,
“namespace” : “m201.people”,
“indexFilterSet” : false,
“parsedQuery” : {
“last_name” : {
“$eq” : “Bailey”
}
},
“winningPlan” : {
“stage” : “FETCH”,
“inputStage” : {
“stage” : “IXSCAN”,
“keyPattern” : {
“last_name” : 1,
“first_name” : 1
},
“indexName” : “idx_test”,
“isMultiKey” : false,
“multiKeyPaths” : {
“last_name” : ,
“first_name” :
},
“isUnique” : false,
“isSparse” : false,
“isPartial” : false,
“indexVersion” : 2,
“direction” : “forward”,
“indexBounds” : {
“last_name” : [
“[“Bailey”, “Bailey”]”
],
“first_name” : [
“[MinKey, MaxKey]”
]
}
}
},
“rejectedPlans” :
},
“serverInfo” : {
“host” : “xxxx”,
“port” : 27000,
“version” : “3.6.15”,
“gitVersion” : “18934fb5c814e87895c5e38ae1515dd6cb4c00f7”
},
“ok” : 1
}

looks like I found it, have to run: db.people.find({“job”:“Jewellery designer”,“employer”:“Baldwin-Nichols”}).explain(“executionStats”)

Optional. Specifies the verbosity mode for the explain output. The mode affects the behavior of explain() and determines the amount of information to return. The possible modes are: "queryPlanner" , "executionStats" , and "allPlansExecution" .

Default mode is "queryPlanner"

1 Like

Here’s some documentation too.