GitHub user hvanhovell opened a pull request:

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

    Make sure CollapseWindow returns the attributes in the same order.

    ## What changes were proposed in this pull request?
    The `CollapseWindow` optimizer rule changes the order of output attributes. 
This modifies the output of the plan, which the optimizer cannot do. This also 
breaks things like `collect()` for which we use a `RowEncoder` that assumes 
that the output attributes of the executed plan are equal to those outputted by 
the logical plan.
    
    ## How was this patch tested?
    I have updated an incorrect test in `CollapseWindowSuite`.
    


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

    $ git pull https://github.com/hvanhovell/spark SPARK-18604

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

    https://github.com/apache/spark/pull/16027.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 #16027
    
----
commit 53b91c83efd0b7d4dba00869dad098ecefbcfdb4
Author: Herman van Hovell <[email protected]>
Date:   2016-11-28T01:18:24Z

    Make sure CollapseWindow returns the attributes in the same order.

----


---
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