Skip to content

Conversation

@AngersZhuuuu
Copy link
Contributor

@AngersZhuuuu AngersZhuuuu commented Jan 6, 2021

What changes were proposed in this pull request?

In #22696 we support HAVING without GROUP BY means global aggregate
But since we treat having as Filter before, in this way will cause a lot of analyze error, after #28294 we use UnresolvedHaving to instead Filter to solve such problem, but break origin logical about treat SELECT 1 FROM range(10) HAVING true as SELECT 1 FROM range(10) WHERE true .
This PR fix this issue and add UT.

NOTE: This backport comes from #31039

Why are the changes needed?

Keep consistent behavior of migration guide.

Does this PR introduce any user-facing change?

No

How was this patch tested?

added UT

@AngersZhuuuu
Copy link
Contributor Author

FYI @maropu

@maropu
Copy link
Member

maropu commented Jan 6, 2021

Looks fine if the tests pass.

@SparkQA
Copy link

SparkQA commented Jan 6, 2021

Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/38289/

@SparkQA
Copy link

SparkQA commented Jan 6, 2021

Kubernetes integration test status success
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/38289/

@SparkQA
Copy link

SparkQA commented Jan 6, 2021

Test build #133701 has finished for PR 31050 at commit aa379b5.

  • This patch fails PySpark unit tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@AngersZhuuuu
Copy link
Contributor Author

retest this please

@SparkQA
Copy link

SparkQA commented Jan 6, 2021

Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/38307/

@SparkQA
Copy link

SparkQA commented Jan 6, 2021

Kubernetes integration test status success
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/38307/

@SparkQA
Copy link

SparkQA commented Jan 6, 2021

Test build #133720 has finished for PR 31050 at commit aa379b5.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

maropu pushed a commit that referenced this pull request Jan 6, 2021
…legacy.parser.havingWithoutGroupByAsWhere` is true with migration guide

### What changes were proposed in this pull request?
In #22696 we support HAVING without GROUP BY means global aggregate
But since we treat having as Filter before, in this way will cause a lot of analyze error, after #28294 we use `UnresolvedHaving` to instead `Filter` to solve such problem, but break origin logical about treat `SELECT 1 FROM range(10) HAVING true` as `SELECT 1 FROM range(10) WHERE true`   .
This PR fix this issue and add UT.

NOTE: This backport comes from #31039

### Why are the changes needed?
Keep consistent behavior of migration guide.

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

### How was this patch tested?
added UT

Closes #31050 from AngersZhuuuu/SPARK-34012-2.4.

Authored-by: angerszhu <[email protected]>
Signed-off-by: Takeshi Yamamuro <[email protected]>
@maropu
Copy link
Member

maropu commented Jan 6, 2021

Thanks! Merged to branch-2.4.

@maropu maropu closed this Jan 6, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants