Update PredicateExpressionsOptimizer.cpp

This commit is contained in:
alexey-milovidov 2019-07-25 04:04:03 +03:00 committed by GitHub
parent 8f3c097c1b
commit 3022c4a759
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -138,10 +138,10 @@ bool PredicateExpressionsOptimizer::allowPushDown(
const std::vector<IdentifierWithQualifier> & dependencies,
OptimizeKind & optimize_kind)
{
if (!subquery ||
(!settings.allow_push_predicate_to_final_subquery && subquery->final()) ||
subquery->limitBy() || subquery->limitLength() ||
subquery->with())
if (!subquery
|| (!settings.enable_optimize_predicate_expression_to_final_subquery && subquery->final())
|| subquery->limitBy() || subquery->limitLength()
|| subquery->with())
return false;
else
{