-
Type:
Improvement
-
Resolution: Unresolved
-
Priority:
Major - P3
-
None
-
Affects Version/s: None
-
Component/s: None
-
Query Optimization
-
None
-
None
-
None
-
None
-
None
-
None
-
None
It is arbitrarily biased in both directions even after SERVER-135566:
db.adminCommand({ setParameter: 1, internalQueryPlanRanker: 'costBased' })
db.a.drop()
// range range point
db.a.createIndex({a:1, c: 1, d: 1})
db.a.insertMany(Array.from({length: 100}, (_, i) => {return {a: i, c: -1};}))
printjson(db.a.explain("executionStats").find({a: {$gt: 0}, c: {$gt: 0}, d: 0}).finish().executionStats.executionStages.inputStage)
This underestimates: 1 vs 100
db.adminCommand({ setParameter: 1, internalQueryPlanRanker: 'costBased' })
db.a.drop()
db.a.createIndex({a:1, b:1, c:1, d: 1})
db.a.insertMany(Array.from({length: 100}, (_, i) => {return {a: i%10, b: 1, c: i, d: 0};}))
db.a.explain("executionStats").find({a: {$gt: 0}, b: 0, c: {$gt: 0}, d: 0})
This overestimates: 100 vs 10
- is related to
-
SERVER-135986 Fix unique document count for projected samples
-
- In Code Review
-
-
SERVER-135994 NDV with bounds on sample is not scaled
-
- In Progress
-
-
SERVER-135566 Fix IndexSeekEstimates for point OILs
-
- Closed
-
-
SERVER-136193 Reduce the number of plans that get handed to multi planner when zero CE
-
- Closed
-
-
SERVER-100611 Better estimation of Index skip scan plans in CBR
-
- Closed
-
-
SERVER-136521 Exclude sort and or from the 0-CE MP fallback
-
- Closed
-
-
SERVER-136693 CBR index seek estimate is close to the collection size when few sample documents satisfy the leading bounds
-
- Needs Scheduling
-