-
- Downloads
[SPARK-14088][SQL] Some Dataset API touch-up
## What changes were proposed in this pull request? 1. Deprecated unionAll. It is pretty confusing to have both "union" and "unionAll" when the two do the same thing in Spark but are different in SQL. 2. Rename reduce in KeyValueGroupedDataset to reduceGroups so it is more consistent with rest of the functions in KeyValueGroupedDataset. Also makes it more obvious what "reduce" and "reduceGroups" mean. Previously it was confusing because it could be reducing a Dataset, or just reducing groups. 3. Added a "name" function, which is more natural to name columns than "as" for non-SQL users. 4. Remove "subtract" function since it is just an alias for "except". ## How was this patch tested? All changes should be covered by existing tests. Also added couple test cases to cover "name". Author: Reynold Xin <rxin@databricks.com> Closes #11908 from rxin/SPARK-14088.
Showing
- project/MimaExcludes.scala 1 addition, 0 deletionsproject/MimaExcludes.scala
- python/pyspark/sql/column.py 2 additions, 0 deletionspython/pyspark/sql/column.py
- python/pyspark/sql/dataframe.py 12 additions, 2 deletionspython/pyspark/sql/dataframe.py
- sql/core/src/main/scala/org/apache/spark/sql/Column.scala 22 additions, 7 deletionssql/core/src/main/scala/org/apache/spark/sql/Column.scala
- sql/core/src/main/scala/org/apache/spark/sql/Dataset.scala 11 additions, 19 deletionssql/core/src/main/scala/org/apache/spark/sql/Dataset.scala
- sql/core/src/main/scala/org/apache/spark/sql/KeyValueGroupedDataset.scala 3 additions, 8 deletions...n/scala/org/apache/spark/sql/KeyValueGroupedDataset.scala
- sql/core/src/test/java/test/org/apache/spark/sql/JavaDatasetSuite.java 2 additions, 2 deletions...test/java/test/org/apache/spark/sql/JavaDatasetSuite.java
- sql/core/src/test/scala/org/apache/spark/sql/ColumnExpressionSuite.scala 2 additions, 1 deletion...st/scala/org/apache/spark/sql/ColumnExpressionSuite.scala
- sql/core/src/test/scala/org/apache/spark/sql/DatasetSuite.scala 1 addition, 1 deletion...re/src/test/scala/org/apache/spark/sql/DatasetSuite.scala
Loading
Please register or sign in to comment