GitHub user gengliangwang opened a pull request:

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

    [WIP][SPARK-19724][SQL]create a managed table with an existed default table 
should throw an exception

    ## What changes were proposed in this pull request?
    This PR is to finish https://github.com/apache/spark/pull/17272
    
    This JIRA is a follow up work after SPARK-19583
    
    As we discussed in that PR
    
    The following DDL for a managed table with an existed default location 
should throw an exception:
    
    CREATE TABLE ... (PARTITIONED BY ...) AS SELECT ...
    CREATE TABLE ... (PARTITIONED BY ...)
    Currently there are some situations which are not consist with above logic:
    
    CREATE TABLE ... (PARTITIONED BY ...) succeed with an existed default 
location
    situation: for both hive/datasource(with 
HiveExternalCatalog/InMemoryCatalog)
    
    CREATE TABLE ... (PARTITIONED BY ...) AS SELECT ...
    situation: hive table succeed with an existed default location
    
    This PR is going to make above two situations consist with the logic that 
it should throw an exception
    with an existed default location.
    ## How was this patch tested?
    
    unit test added
    
    


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

    $ git pull https://github.com/gengliangwang/spark pr-17272

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

    https://github.com/apache/spark/pull/20886.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 #20886
    
----
commit d584c9b6dd97addf0d993fa4a6dfd85fd2b94a95
Author: windpiger <songjun@...>
Date:   2018-03-22T13:19:21Z

    [SPARK-19724][SQL]create a managed table with an existed default table 
should throw an exception

----


---

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

Reply via email to