Github user maryannxue commented on a diff in the pull request:

    https://github.com/apache/spark/pull/21720#discussion_r201136705
  
    --- Diff: 
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/analysis/Analyzer.scala
 ---
    @@ -506,7 +506,7 @@ class Analyzer(
         def apply(plan: LogicalPlan): LogicalPlan = plan transform {
           case p: Pivot if !p.childrenResolved || 
!p.aggregates.forall(_.resolved)
             || (p.groupByExprsOpt.isDefined && 
!p.groupByExprsOpt.get.forall(_.resolved))
    -        || !p.pivotColumn.resolved => p
    +        || !p.pivotColumn.resolved || !p.pivotValues.forall(_.resolved) => 
p
    --- End diff --
    
    Before this PR, pivot values can only be single literals (no struct) so 
they have been converted to Literals in ASTBuilder. Now they are "expressions" 
and will be handled in this Analyzer rule.


---

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org

Reply via email to