This is an automated email from the ASF dual-hosted git repository.
maxgekk pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/spark.git
The following commit(s) were added to refs/heads/master by this push:
new 3093ad68d2a3 [MINOR] Fix a typo in First aggregate expression
3093ad68d2a3 is described below
commit 3093ad68d2a3c6bab9c1605381d27e700766be22
Author: exmy <[email protected]>
AuthorDate: Tue Oct 1 15:22:29 2024 +0200
[MINOR] Fix a typo in First aggregate expression
### What changes were proposed in this pull request?
Find a typo for the comment on code `mergeExpressions` of `First` aggregate
expression, fix from `first.right` to `first.left`.
### Why are the changes needed?
Fix typo, it's confused.
### Does this PR introduce _any_ user-facing change?
No
### How was this patch tested?
N.A
### Was this patch authored or co-authored using generative AI tooling?
No
Closes #48298 from exmy/fix-comment.
Authored-by: exmy <[email protected]>
Signed-off-by: Max Gekk <[email protected]>
---
.../org/apache/spark/sql/catalyst/expressions/aggregate/First.scala | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git
a/sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/aggregate/First.scala
b/sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/aggregate/First.scala
index 4fe00099ddc9..9a39a6fe9879 100644
---
a/sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/aggregate/First.scala
+++
b/sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/aggregate/First.scala
@@ -104,7 +104,7 @@ case class First(child: Expression, ignoreNulls: Boolean)
override lazy val mergeExpressions: Seq[Expression] = {
// For first, we can just check if valueSet.left is set to true. If it is
set
- // to true, we use first.right. If not, we use first.right (even if
valueSet.right is
+ // to true, we use first.left. If not, we use first.right (even if
valueSet.right is
// false, we are safe to do so because first.right will be null in this
case).
Seq(
/* first = */ If(valueSet.left, first.left, first.right),
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]