GitHub user sureshthalamati opened a pull request:

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

    SPARK-14218][SQL] Use encoder schema for generating dataset show output to 
match the column names with the data.

    ## What changes were proposed in this pull request?
    Data is displayed in the schema order of the encoder, but the column names 
are displayed in the order of the underlying data frame schema, this results in 
mismatch of column names and the data in the output. This PR modifies the 
schema used in the showString() method to the encoder schema. 
    
    ## How was this patch tested?
    Added a new unit test case to check the output of showString when the 
schema orders are different. 
    
    @liancheng

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

    $ git pull https://github.com/sureshthalamati/spark 
dataset_show_column_name_fix-SPARK-14218

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

    https://github.com/apache/spark/pull/12019.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 #12019
    
----
commit a5ec52140fccee00e3738b886b16fa078853e9cb
Author: sureshthalamati <[email protected]>
Date:   2016-03-28T23:52:17Z

    Modified the schema used by the dataset show method to display the column 
names to the encoder schema to match with the data output 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