diff options
author | Anton Guryanov <guryanov91@gmail.com> | 2016-07-14 16:20:20 +0300 |
---|---|---|
committer | David Storch <david.storch@10gen.com> | 2016-08-25 13:07:21 -0400 |
commit | 1101287cc7789e9b8b52ba370cee55678aa6c58d (patch) | |
tree | b56e85a7f98dc4ca4ed8b9ff01e0146f642b7085 /jstests/core/explain_distinct.js | |
parent | 46b33e042de75d801e5fd9f20b74a1c9a249b0c2 (diff) | |
download | mongo-1101287cc7789e9b8b52ba370cee55678aa6c58d.tar.gz |
SERVER-19507 allow DISTINCT_SCAN over trailing field of an index
Closes #1101
Signed-off-by: David Storch <david.storch@10gen.com>
Diffstat (limited to 'jstests/core/explain_distinct.js')
-rw-r--r-- | jstests/core/explain_distinct.js | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/jstests/core/explain_distinct.js b/jstests/core/explain_distinct.js index 57e5f55e065..f2908caa5e7 100644 --- a/jstests/core/explain_distinct.js +++ b/jstests/core/explain_distinct.js @@ -80,7 +80,8 @@ assert.eq([1], coll.distinct('b', {a: 1})); var explain = runDistinctExplain(coll, 'b', {a: 1}); assert.commandWorked(explain); - assert.eq(10, explain.executionStats.nReturned); - assert(planHasStage(explain.queryPlanner.winningPlan, "FETCH")); - assert(isIxscan(explain.queryPlanner.winningPlan)); + assert.eq(1, explain.executionStats.nReturned); + assert(!planHasStage(explain.queryPlanner.winningPlan, "FETCH")); + assert(planHasStage(explain.queryPlanner.winningPlan, "PROJECTION")); + assert(planHasStage(explain.queryPlanner.winningPlan, "DISTINCT_SCAN")); })(); |