GitHub user gatorsmile opened a pull request:

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

    [SPARK-14993] Fix Partition Discovery Inconsistency when Input is a Path to 
Parquet File 

    #### What changes were proposed in this pull request?
    When we load a dataset, if we set the path to ```/path/a=1```, we will not 
take `a` as the partitioning column. However, if we set the path to 
```/path/a=1/file.parquet```, we take `a` as the partitioning column and it 
shows up in the schema. 
    
    This PR is to fix the issue. If users set the path to a Parquet file, we do 
not include the partitioning columns into the schema. 
    
    The related PRs: 
    - https://github.com/apache/spark/pull/9651
    - https://github.com/apache/spark/pull/10211
    
    #### How was this patch tested?
    Added a couple of test cases

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

    $ git pull https://github.com/gatorsmile/spark readPartitionedTable

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

    https://github.com/apache/spark/pull/12828.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 #12828
    
----
commit 461441c8acdfce8e175f34ba44b0d08dea761225
Author: gatorsmile <gatorsm...@gmail.com>
Date:   2016-05-02T02:29:49Z

    initial fix.

----


---
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 infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org

Reply via email to