Skip to content

Commit

Permalink
Stop copying LogicalPlan and Exprs in PushDownFilter (apache#10444)
Browse files Browse the repository at this point in the history
  • Loading branch information
alamb authored and findepi committed Jul 16, 2024
1 parent b27235e commit c706286
Show file tree
Hide file tree
Showing 2 changed files with 343 additions and 290 deletions.
10 changes: 10 additions & 0 deletions datafusion/expr/src/logical_plan/plan.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2407,6 +2407,16 @@ pub enum Distinct {
On(DistinctOn),
}

impl Distinct {
/// return a reference to the nodes input
pub fn input(&self) -> &Arc<LogicalPlan> {
match self {
Distinct::All(input) => input,
Distinct::On(DistinctOn { input, .. }) => input,
}
}
}

/// Removes duplicate rows from the input
#[derive(Clone, PartialEq, Eq, Hash)]
pub struct DistinctOn {
Expand Down
Loading

0 comments on commit c706286

Please sign in to comment.