mirror of https://gitee.com/bigwinds/arangodb
fixes
This commit is contained in:
parent
5416755049
commit
b6606727ee
|
@ -4349,7 +4349,7 @@ bool applyGeoOptimization(bool near, ExecutionPlan* plan, GeoIndexInfo& info){
|
||||||
// avoid other constructs between sort/filter and enumerate collection
|
// avoid other constructs between sort/filter and enumerate collection
|
||||||
ExecutionNode* current = res.executionNode->getFirstDependency();
|
ExecutionNode* current = res.executionNode->getFirstDependency();
|
||||||
ExecutionNode* end = res.collectionNode;
|
ExecutionNode* end = res.collectionNode;
|
||||||
while(current != end){
|
while(current != end && current != nullptr){
|
||||||
if( current->getType() == EN::SORT
|
if( current->getType() == EN::SORT
|
||||||
|| current->getType() == EN::COLLECT
|
|| current->getType() == EN::COLLECT
|
||||||
|| current->getType() == EN::FILTER
|
|| current->getType() == EN::FILTER
|
||||||
|
@ -4362,7 +4362,7 @@ bool applyGeoOptimization(bool near, ExecutionPlan* plan, GeoIndexInfo& info){
|
||||||
}
|
}
|
||||||
|
|
||||||
// avoid sorts above index node
|
// avoid sorts above index node
|
||||||
while(current != plan->root()){
|
while(current != plan->root() && current != nullptr){
|
||||||
if(current->getType() == EN::SORT){
|
if(current->getType() == EN::SORT){
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
@ -4425,6 +4425,6 @@ void arangodb::aql::geoIndexRule(Optimizer* opt,
|
||||||
}
|
}
|
||||||
opt->addPlan(plan, rule, modified);
|
opt->addPlan(plan, rule, modified);
|
||||||
|
|
||||||
LOG_TOPIC(DEBUG, Logger::DEVEL) << "EXIT GEO RULE - modified: " << modified;
|
//LOG_TOPIC(DEBUG, Logger::DEVEL) << "EXIT GEO RULE - modified: " << modified;
|
||||||
//LOG_TOPIC(DEBUG, Logger::DEVEL) << "";
|
//LOG_TOPIC(DEBUG, Logger::DEVEL) << "";
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue