Skip to content

Commit

Permalink
Address comments
Browse files Browse the repository at this point in the history
  • Loading branch information
zhuqi-lucas committed Jan 29, 2025
1 parent ee2bda7 commit 412b104
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions datafusion/physical-optimizer/src/limit_pushdown.rs
Original file line number Diff line number Diff line change
Expand Up @@ -249,12 +249,12 @@ pub fn pushdown_limit_helper(
// Add fetch or a `LimitExec`:
// If the plan's children have limit and the child's limit < parent's limit, we shouldn't change the global state to true,
// because the children limit will be overridden if the global state is changed.
if pushdown_plan
if !pushdown_plan
.children()
.iter()
.any(|&child| extract_limit(child).is_some())
{
global_state.satisfied = false;
global_state.satisfied = true;
}
pushdown_plan = if let Some(plan_with_fetch) = maybe_fetchable {
if global_skip > 0 {
Expand Down

0 comments on commit 412b104

Please sign in to comment.