summaryrefslogtreecommitdiff
path: root/src/mongo/db/exec/idhack.cpp
diff options
context:
space:
mode:
authorMisha Ivkov <misha.ivkov@10gen.com>2019-07-11 11:09:35 -0400
committerMisha Ivkov <misha.ivkov@10gen.com>2019-07-22 17:46:47 -0400
commit9efa2b1d4d2fd59f7480d3a8d6d3f8b6c1591732 (patch)
tree559b9949502405c9d47a3566c6899ae12f1b40e5 /src/mongo/db/exec/idhack.cpp
parentbe18bd1133d6f8118ebb79a2251c4a49b1c84ec1 (diff)
downloadmongo-9efa2b1d4d2fd59f7480d3a8d6d3f8b6c1591732.tar.gz
SERVER-12916 ensure find on _id field obeys min/max.
Diffstat (limited to 'src/mongo/db/exec/idhack.cpp')
-rw-r--r--src/mongo/db/exec/idhack.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/mongo/db/exec/idhack.cpp b/src/mongo/db/exec/idhack.cpp
index 8cd352fa046..b287dc12531 100644
--- a/src/mongo/db/exec/idhack.cpp
+++ b/src/mongo/db/exec/idhack.cpp
@@ -165,6 +165,7 @@ void IDHackStage::doReattachToOperationContext() {
// static
bool IDHackStage::supportsQuery(Collection* collection, const CanonicalQuery& query) {
return !query.getQueryRequest().showRecordId() && query.getQueryRequest().getHint().isEmpty() &&
+ query.getQueryRequest().getMin().isEmpty() && query.getQueryRequest().getMax().isEmpty() &&
!query.getQueryRequest().getSkip() &&
CanonicalQuery::isSimpleIdQuery(query.getQueryRequest().getFilter()) &&
!query.getQueryRequest().isTailable() &&