GitHub user ymwdalex opened a pull request:

    https://github.com/apache/hive/pull/273

    HIVE-18130: Update table path to storage parameters when alter a table

    When an managed table is created by Spark, table path information is not 
only store in `location` field (first figure), but also in `parameters.path` 
fields (second figure).
    <img width="445" alt="location" 
src="https://user-images.githubusercontent.com/1458656/33123050-466c6bdc-cf79-11e7-8b53-85ad7dc83f17.png";>
    <img width="677" alt="storage_parameter" 
src="https://user-images.githubusercontent.com/1458656/33123051-469576da-cf79-11e7-9c6c-9793a28f8389.png";>
    
    When hive alter a table, `storage parameter` is ignored. Then, spark cannot 
access the table anymore because spark use the parameter.
    
    In this PR, when altering a table, the field 
`storageDescription.parameters.path` is also updated, if `path` key exists
    


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

    $ git pull https://github.com/ymwdalex/hive 
HIVE-18130-update-storage-parameters-when-alter-table

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

    https://github.com/apache/hive/pull/273.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 #273
    
----
commit 639193346dd19b8bfa619257f1ac2a7d3014f1e9
Author: Zhe Sun <ymwda...@gmail.com>
Date:   2017-11-22T10:32:16Z

    HIVE-18130: Update table path to storage parameters when alter a table

----


---

Reply via email to