You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2021/03/11 08:29:55 UTC
[GitHub] [spark] cloud-fan commented on a change in pull request #31808: [SPARK-34713][SQL] Fix group by CreateStruct with ExtractValue
cloud-fan commented on a change in pull request #31808:
URL: https://github.com/apache/spark/pull/31808#discussion_r592155909
##########
File path: sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/complexTypeExtractors.scala
##########
@@ -448,6 +453,10 @@ case class GetMapValue(
override def toString: String = s"$child[$key]"
override def sql: String = s"${child.sql}[${key.sql}]"
+ override def name: Option[String] = key match {
+ case NonNullLiteral(s, StringType) => Some(s.toString)
+ case _ => None
Review comment:
e.g. `col[1]` to get the map value. It's not a single `UnresolvedAttribute` (multi-part name like `a.b.c`) and is unrelated to this bug fix
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org