You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by ouyangxiaochen <gi...@git.apache.org> on 2017/03/13 02:47:57 UTC

[GitHub] spark pull request #17270: [SPARK-19929] [SQL] Showing Hive Managed table's ...

GitHub user ouyangxiaochen opened a pull request:

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

    [SPARK-19929] [SQL] Showing Hive Managed table's LOATION when Using 'show create table ...'

    ## What changes were proposed in this pull request?
    
    Show Hive table's LOCATION property When we using the command 'show create table ...' on Hive MANAGED table
    
    ## How was this patch tested?
    manual test


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

    $ git pull https://github.com/ouyangxiaochen/spark spark-19929

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

    https://github.com/apache/spark/pull/17270.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 #17270
    
----
commit cf5bf30bea8ec2c6e760abce84022616df63951b
Author: \u6b27\u9633\u6653\u666810208179 <ou...@zte.com.cn>
Date:   2017-03-10T03:12:42Z

    fvff

commit f8396b67c220158b1bb444748fcd2ade27ccb369
Author: ouyangxiaochen <ou...@zte.com.cn>
Date:   2017-03-13T02:40:49Z

    Hive EXTERNAL table and Hive Managed table should show LOCATION properties

----


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

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


[GitHub] spark issue #17270: [SPARK-19929] [SQL] Showing Hive Managed table's LOATION...

Posted by gatorsmile <gi...@git.apache.org>.
Github user gatorsmile commented on the issue:

    https://github.com/apache/spark/pull/17270
  
    Yeah. you need to close the PR by yourself. We are unable to close it. thanks


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

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


[GitHub] spark issue #17270: [SPARK-19929] [SQL] Showing Hive Managed table's LOATION...

Posted by ouyangxiaochen <gi...@git.apache.org>.
Github user ouyangxiaochen commented on the issue:

    https://github.com/apache/spark/pull/17270
  
    As an application developer we want to know hive table's location, we can use  the command  'show create table ...' to get the table's data location when the hive table is EXTERNAL but MANAGED. 
    So, I think both hive EXTERNAL table and hive MANAGED table should show the LOACATION property, it can be conveniently and friendly for the user.


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

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


[GitHub] spark pull request #17270: [SPARK-19929] [SQL] Showing Hive Managed table's ...

Posted by gatorsmile <gi...@git.apache.org>.
Github user gatorsmile commented on a diff in the pull request:

    https://github.com/apache/spark/pull/17270#discussion_r106313999
  
    --- Diff: sql/core/src/main/scala/org/apache/spark/sql/execution/command/tables.scala ---
    @@ -910,7 +910,7 @@ case class ShowCreateTableCommand(table: TableIdentifier) extends RunnableComman
           }
         }
     
    -    if (metadata.tableType == EXTERNAL) {
    +    if (metadata.tableType == EXTERNAL || metadata.tableType == MANAGED) {
    --- End diff --
    
    > SHOW CREATE TABLE shows the CREATE TABLE statement that creates a given table, or the CREATE VIEW statement that creates a given view.
    
    If we add the location clause for managed tables, CREATE TABLE will create an external table instead of a managed table. That is not what we want. 


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

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


[GitHub] spark issue #17270: [SPARK-19929] [SQL] Showing Hive Managed table's LOATION...

Posted by ouyangxiaochen <gi...@git.apache.org>.
Github user ouyangxiaochen commented on the issue:

    https://github.com/apache/spark/pull/17270
  
    Yeah, U are right. 
    In Hive. the table is created by specifing LOCATION that will be a MANAGED table.
    In Spark2.x. the table is created by specifing LOCATION that will be an EXTERNAL table.
    So, Hive\u2019s logical and Spark2.x's logical are reasonable. Please close the issue, Thanks!


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

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


[GitHub] spark issue #17270: [SPARK-19929] [SQL] Showing Hive Managed table's LOATION...

Posted by gatorsmile <gi...@git.apache.org>.
Github user gatorsmile commented on the issue:

    https://github.com/apache/spark/pull/17270
  
    If you want to know hive table's location, you can use the command `DESCRIBE EXTENDED` , right?


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

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


[GitHub] spark issue #17270: [SPARK-19929] [SQL] Showing Hive Managed table's LOATION...

Posted by AmplabJenkins <gi...@git.apache.org>.
Github user AmplabJenkins commented on the issue:

    https://github.com/apache/spark/pull/17270
  
    Can one of the admins verify this patch?


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

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


[GitHub] spark issue #17270: [SPARK-19929] [SQL] Showing Hive Managed table's LOATION...

Posted by ouyangxiaochen <gi...@git.apache.org>.
Github user ouyangxiaochen commented on the issue:

    https://github.com/apache/spark/pull/17270
  
    @gatorsmile cc ,is it reasonable? Thanks!


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

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


[GitHub] spark pull request #17270: [SPARK-19929] [SQL] Showing Hive Managed table's ...

Posted by ouyangxiaochen <gi...@git.apache.org>.
Github user ouyangxiaochen closed the pull request at:

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


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

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