Hi Team ,
I am getting below error , while running explain plan using a hint with index.
db.collection.explain().find({“createdDateUTC” : ISODate(“2021-04-14T00:48:30.820Z”)}).hint({“createdDateUTC”:1});
uncaught exception: Error: explain failed: {
“operationTime” : Timestamp(1678115286, 84),
“ok” : 0,
“errmsg” : “error processing query: ns=ATTPT.davidTree: createdDateUTC $gt new Date(1618361310820)\nSort: {}\nProj: {}\n planner returned error :: caused by :: hint provided does not correspond to an existing index”,
“code” : 2,
“codeName” : “BadValue”,
“$clusterTime” : {
“clusterTime” : Timestamp(1678115286, 84),
“signature” : {
“hash” : BinData(0,“cRm/DMwcuvEC13V1XLzhqpXdIZA=”),
“keyId” : NumberLong(“7154570222622474241”)
}
}
}
.