Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[MINOR]: Simplify required_input_ordering of BoundedWindowAggExec #12656

Merged
merged 1 commit into from
Oct 1, 2024

Conversation

akurmustafa
Copy link
Contributor

Which issue does this PR close?

Closes #.

Rationale for this change

What changes are included in this PR?

Simplify required_input_ordering method of the BoundedWindowAggExec.

Are these changes tested?

Are there any user-facing changes?

@github-actions github-actions bot added the physical-expr Physical Expressions label Sep 27, 2024
.map(|idx| &partition_bys[*idx]);
vec![calc_requirements(partition_bys, order_keys)]
} else {
vec![calc_requirements(partition_bys, order_keys)]
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

when self.input_order_mode is InputOrderMode::Sorted, it is guaranteed that self.ordered_partition_by_indices.len() == partition_bys.len(). Hence, else branch was never being triggerred in the previous version. I think, that check is redundant.

Copy link
Contributor

@alamb alamb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you @akurmustafa

@comphead comphead merged commit 2c2e0e7 into apache:main Oct 1, 2024
24 checks passed
@akurmustafa akurmustafa deleted the simplifications/bounded_window branch October 1, 2024 22:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
physical-expr Physical Expressions
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants