GitHub user maryannxue opened a pull request: https://github.com/apache/spark/pull/21753
[SPARK-24790][SQL] Allow complex aggregate expressions in Pivot ## What changes were proposed in this pull request? Relax the check to allow complex aggregate expressions, like `ceil(sum(col1))` or `sum(col1) + 1`, which roughly means any aggregate expression that could appear in an Aggregate plan except pandas UDF (due to the fact that it is not supported in pivot yet). ## How was this patch tested? Added 2 tests in pivot.sql You can merge this pull request into a Git repository by running: $ git pull https://github.com/maryannxue/spark pivot-relax-syntax Alternatively you can review and apply these changes as the patch at: https://github.com/apache/spark/pull/21753.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #21753 ---- commit 93d2bde8c01b626456094f049911f976d1c1660d Author: maryannxue <maryannxue@...> Date: 2018-07-11T22:50:50Z [SPARK-24790] Allow complex aggregate expressions in Pivot ---- --- --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org