GitHub user marmbrus opened a pull request:

    https://github.com/apache/spark/pull/9499

    [SPARK-11528] [SQL] Typed aggregations for Datasets

    This PR adds the ability to do typed SQL aggregations.  We will likely also 
want to provide an interface to allow users to do aggregations on objects, but 
this is deferred to another PR.
    
    ```scala
    val ds = Seq(("a", 10), ("a", 20), ("b", 1), ("b", 2), ("c", 1)).toDS()
    ds.groupBy(_._1).agg(sum("_2").as[Int]).collect()
    
    res0: Array(("a", 30), ("b", 3), ("c", 1))
    ```

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/marmbrus/spark dataset-agg

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/spark/pull/9499.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 #9499
    
----
commit 6d40e4294b224f18235c9a9ca44b8ccddcf6b6f6
Author: Michael Armbrust <[email protected]>
Date:   2015-11-05T18:05:14Z

    [SPARK-11528] [SQL] Typed aggregations for Datasets

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to