-
Notifications
You must be signed in to change notification settings - Fork 29k
[SPARK-9740] [SPARK-9592] [SPARK-9210] [SQL] Change the default behavior of First/Last to RESPECT NULLS. #8113
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
Conversation
|
@hvanhovell I am making the default in this PR. |
|
Test build #40531 has finished for PR 8113 at commit
|
|
One final question, shouldn't we introduce a |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We could for now simplify this to Literal.create(true, BooleanType).
|
yeah. I think that only requires a small change. Let me add it. |
|
Besides the |
|
@hvanhovell Alright. I added the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ggupta81 This is the fix of SPARK-9592 for our master and 1.5 branch.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@yhuai Both if and else branches are executing the same code.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
oops. Will fix it.
|
Should i close my original pull request now? On Wed, Aug 12, 2015 at 10:38 AM, UCB AMPLab notifications@github.com
_Gaurav Gupta_Engineering Manager @ Adobe |
|
Test build #40589 has finished for PR 8113 at commit
|
|
Test build #1488 has finished for PR 8113 at commit
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: Or(valueSet, Not(IsNull(child))) is a bit shorter. It is a matter of preference though...
|
One more small thing. We should probably also add the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: Or(valueSet.left. valueSet.right) is shorter.
|
@hvanhovell Since we already pass the feature freeze deadline, I will not add new interfaces to DataFrame API (this PR is mainly about fixing the default behavior). If users request adding DF functions that expose |
|
Test build #40705 has finished for PR 8113 at commit
|
|
Test build #40724 has finished for PR 8113 at commit
|
|
Test build #1542 has finished for PR 8113 at commit
|
|
Test build #1551 timed out for PR 8113 at commit |
…pression1. https://issues.apache.org/jira/browse/SPARK-9592 #8113 has the fundamental fix. But, if we want to minimize the number of changed lines, we can go with this one. Then, in 1.6, we merge #8113. Author: Yin Huai <yhuai@databricks.com> Closes #8172 from yhuai/lastFix and squashes the following commits: b28c42a [Yin Huai] Regression test. af87086 [Yin Huai] Fix last. (cherry picked from commit 772e7c1) Signed-off-by: Michael Armbrust <michael@databricks.com>
…pression1. https://issues.apache.org/jira/browse/SPARK-9592 #8113 has the fundamental fix. But, if we want to minimize the number of changed lines, we can go with this one. Then, in 1.6, we merge #8113. Author: Yin Huai <yhuai@databricks.com> Closes #8172 from yhuai/lastFix and squashes the following commits: b28c42a [Yin Huai] Regression test. af87086 [Yin Huai] Fix last.
Conflicts: sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/aggregate/functions.scala sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/aggregates.scala
|
test this please |
|
Test build #43948 has finished for PR 8113 at commit
|
|
Thanks! Merging to master. |
I am changing the default behavior of
First/Lastto respect null values (the SQL standard default behavior).https://issues.apache.org/jira/browse/SPARK-9740