Skip to content

Commit

Permalink
Simplifications (#12656)
Browse files Browse the repository at this point in the history
  • Loading branch information
akurmustafa authored Oct 1, 2024
1 parent 84ac4f9 commit 2c2e0e7
Showing 1 changed file with 5 additions and 11 deletions.
16 changes: 5 additions & 11 deletions datafusion/physical-plan/src/windows/bounded_window_agg_exec.rs
Original file line number Diff line number Diff line change
Expand Up @@ -257,17 +257,11 @@ impl ExecutionPlan for BoundedWindowAggExec {
fn required_input_ordering(&self) -> Vec<Option<LexRequirement>> {
let partition_bys = self.window_expr()[0].partition_by();
let order_keys = self.window_expr()[0].order_by();
if self.input_order_mode != InputOrderMode::Sorted
|| self.ordered_partition_by_indices.len() >= partition_bys.len()
{
let partition_bys = self
.ordered_partition_by_indices
.iter()
.map(|idx| &partition_bys[*idx]);
vec![calc_requirements(partition_bys, order_keys)]
} else {
vec![calc_requirements(partition_bys, order_keys)]
}
let partition_bys = self
.ordered_partition_by_indices
.iter()
.map(|idx| &partition_bys[*idx]);
vec![calc_requirements(partition_bys, order_keys)]
}

fn required_input_distribution(&self) -> Vec<Distribution> {
Expand Down

0 comments on commit 2c2e0e7

Please sign in to comment.