diff options
Diffstat (limited to 'src/mongo/db/query_optimizer_internal.cpp')
-rw-r--r-- | src/mongo/db/query_optimizer_internal.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/mongo/db/query_optimizer_internal.cpp b/src/mongo/db/query_optimizer_internal.cpp index dcd7516b357..c94212c1deb 100644 --- a/src/mongo/db/query_optimizer_internal.cpp +++ b/src/mongo/db/query_optimizer_internal.cpp @@ -545,7 +545,7 @@ namespace mongo { int j = i.pos(); IndexDetails& ii = i.next(); BSONObj keyPattern = ii.keyPattern(); - string pluginName = CatalogHack::findPluginName(keyPattern); + string pluginName = CatalogHack::getAccessMethodName(keyPattern); if (special.has(pluginName) && (USELESS != IndexSelection::isSuitableFor(keyPattern, _qps.frsp().frsForIndex(d, j), _qps.order()))) { @@ -1497,8 +1497,7 @@ namespace mongo { while( i.more() ) { IndexDetails& ii = i.next(); if ( indexWorks( ii.keyPattern(), min.isEmpty() ? max : min, ret.first, ret.second ) ) { - if ( ii.getSpec().getTypeName().empty()) { - //if ( ii.getSpec().getType() == 0 ) { + if (CatalogHack::getAccessMethodName(ii.keyPattern()).empty()) { id = ⅈ keyPattern = ii.keyPattern(); break; |