Skip to content

Conversation

@wangyum
Copy link
Member

@wangyum wangyum commented Mar 10, 2022

What changes were proposed in this pull request?

This pr makes Aggregate.groupOnly support foldable expressions.

Why are the changes needed?

Improve query performance.

Does this PR introduce any user-facing change?

No.

How was this patch tested?

Unit test.

Copy link
Contributor

@cloud-fan cloud-fan left a comment

Choose a reason for hiding this comment

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

I checked all the caller sides of groupOnly, all look fine

@cloud-fan
Copy link
Contributor

AggregateOptimizeSuite.SPARK-34808: aggregateExpressions only contains groupingExpressions fails

@wangyum
Copy link
Member Author

wangyum commented Mar 10, 2022

Fixed it.

@cloud-fan
Copy link
Contributor

thanks, merging to master!

@cloud-fan cloud-fan closed this in bcf7849 Mar 10, 2022
@wangyum wangyum deleted the SPARK-38489 branch March 10, 2022 12:25
wangyum added a commit that referenced this pull request May 26, 2023
…tributes (#884)

* Remove the aggregation from left semi/anti join if the same aggregation has already been done on left side

* Add more test

* grouping -> groupingExps

* Add DistinctAttributesVisitor

* Fix test name

* Improve DistinctAttributesVisitor

* Fix test.

* DistinctKeyVisitor

* Address comments

* Fix scala 2.13

* Address comments

* Address all comments

* Address all comments

* fix

* fix test

* [SPARK-38489][SQL] Aggregate.groupOnly support foldable expressions

### What changes were proposed in this pull request?

This pr makes `Aggregate.groupOnly` support foldable expressions.

### Why are the changes needed?

Improve query performance.

### Does this PR introduce _any_ user-facing change?

No.

### How was this patch tested?

Unit test.

Closes #35795 from wangyum/SPARK-38489.

Authored-by: Yuming Wang <[email protected]>
Signed-off-by: Wenchen Fan <[email protected]>

(cherry picked from commit bcf7849)

* Remove

* fix

* Update DistinctKeyVisitor.scala
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants