You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by guoxiaolongzte <gi...@git.apache.org> on 2018/01/09 02:44:31 UTC

[GitHub] spark pull request #20194: [SPARK-22999][SQL]'show databases like command' c...

GitHub user guoxiaolongzte opened a pull request:

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

    [SPARK-22999][SQL]'show databases like command' can remove the like keyword

    ## What changes were proposed in this pull request?
    
    SHOW DATABASES (LIKE pattern = STRING)? Can be like the back increase?
    When using this command, LIKE keyword can be removed. 
    You can refer to the SHOW TABLES command, SHOW TABLES 'test *' and SHOW TABELS like 'test *' can be used. 
    Similarly SHOW DATABASES 'test *' and SHOW DATABASES like 'test *' can be used.
    
    ## How was this patch tested?
    unit tests   manual tests
    Please review http://spark.apache.org/contributing.html before opening a pull request.


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

    $ git pull https://github.com/guoxiaolongzte/spark SPARK-22999

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

    https://github.com/apache/spark/pull/20194.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 #20194
    
----
commit 26e7c0d22b07144502eb5e05343d6a78824a1f1b
Author: guoxiaolong <gu...@...>
Date:   2018-01-09T02:40:39Z

    [SPARK-22999][SQL]'show databases like command' can remove the like keyword

----


---

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


[GitHub] spark issue #20194: [SPARK-22999][SQL]'show databases like command' can remo...

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

    https://github.com/apache/spark/pull/20194
  
    OK to test


---

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


[GitHub] spark issue #20194: [SPARK-22999][SQL]'show databases like command' can remo...

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

    https://github.com/apache/spark/pull/20194
  
    Merged build finished. Test PASSed.


---

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


[GitHub] spark issue #20194: [SPARK-22999][SQL]'show databases like command' can remo...

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

    https://github.com/apache/spark/pull/20194
  
    ok to test


---

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


[GitHub] spark issue #20194: [SPARK-22999][SQL]'show databases like command' can remo...

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

    https://github.com/apache/spark/pull/20194
  
    Test PASSed.
    Refer to this link for build results (access rights to CI server needed): 
    https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/86120/
    Test PASSed.


---

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


[GitHub] spark pull request #20194: [SPARK-22999][SQL]'show databases like command' c...

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

    https://github.com/apache/spark/pull/20194#discussion_r161000312
  
    --- Diff: sql/catalyst/src/main/antlr4/org/apache/spark/sql/catalyst/parser/SqlBase.g4 ---
    @@ -141,7 +141,7 @@ statement
             (LIKE? pattern=STRING)?                                        #showTables
         | SHOW TABLE EXTENDED ((FROM | IN) db=identifier)?
             LIKE pattern=STRING partitionSpec?                             #showTable
    -    | SHOW DATABASES (LIKE pattern=STRING)?                            #showDatabases
    +    | SHOW DATABASES (LIKE? pattern=STRING)?                            #showDatabases
    --- End diff --
    
    Impala is the only reference I can find https://www.cloudera.com/documentation/enterprise/5-10-x/topics/impala_show.html
    
    To be consistent with the other SHOW function, we can make LIKE optional?


---

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


[GitHub] spark issue #20194: [SPARK-22999][SQL]'show databases like command' can remo...

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

    https://github.com/apache/spark/pull/20194
  
    **[Test build #86120 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/86120/testReport)** for PR 20194 at commit [`26e7c0d`](https://github.com/apache/spark/commit/26e7c0d22b07144502eb5e05343d6a78824a1f1b).


---

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


[GitHub] spark pull request #20194: [SPARK-22999][SQL]'show databases like command' c...

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

    https://github.com/apache/spark/pull/20194#discussion_r161130352
  
    --- Diff: sql/catalyst/src/main/antlr4/org/apache/spark/sql/catalyst/parser/SqlBase.g4 ---
    @@ -141,7 +141,7 @@ statement
             (LIKE? pattern=STRING)?                                        #showTables
         | SHOW TABLE EXTENDED ((FROM | IN) db=identifier)?
             LIKE pattern=STRING partitionSpec?                             #showTable
    -    | SHOW DATABASES (LIKE pattern=STRING)?                            #showDatabases
    +    | SHOW DATABASES (LIKE? pattern=STRING)?                            #showDatabases
    --- End diff --
    
    @gatorsmile  @dongjoon-hyun 
    I think we can make LIKE optional.


---

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


[GitHub] spark pull request #20194: [SPARK-22999][SQL]'show databases like command' c...

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

    https://github.com/apache/spark/pull/20194#discussion_r160313038
  
    --- Diff: sql/catalyst/src/main/antlr4/org/apache/spark/sql/catalyst/parser/SqlBase.g4 ---
    @@ -141,7 +141,7 @@ statement
             (LIKE? pattern=STRING)?                                        #showTables
         | SHOW TABLE EXTENDED ((FROM | IN) db=identifier)?
             LIKE pattern=STRING partitionSpec?                             #showTable
    -    | SHOW DATABASES (LIKE pattern=STRING)?                            #showDatabases
    +    | SHOW DATABASES (LIKE? pattern=STRING)?                            #showDatabases
    --- End diff --
    
    Hive did not change, but I think spark can change the next.


---

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


[GitHub] spark issue #20194: [SPARK-22999][SQL]'show databases like command' can remo...

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

    https://github.com/apache/spark/pull/20194
  
    test this please


---

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


[GitHub] spark issue #20194: [SPARK-22999][SQL]'show databases like command' can remo...

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

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


---

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


[GitHub] spark pull request #20194: [SPARK-22999][SQL]'show databases like command' c...

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

    https://github.com/apache/spark/pull/20194#discussion_r160310488
  
    --- Diff: sql/catalyst/src/main/antlr4/org/apache/spark/sql/catalyst/parser/SqlBase.g4 ---
    @@ -141,7 +141,7 @@ statement
             (LIKE? pattern=STRING)?                                        #showTables
         | SHOW TABLE EXTENDED ((FROM | IN) db=identifier)?
             LIKE pattern=STRING partitionSpec?                             #showTable
    -    | SHOW DATABASES (LIKE pattern=STRING)?                            #showDatabases
    +    | SHOW DATABASES (LIKE? pattern=STRING)?                            #showDatabases
    --- End diff --
    
    We are following Hive. Any change was made in the recent releases of Hive?


---

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


[GitHub] spark pull request #20194: [SPARK-22999][SQL]'show databases like command' c...

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

    https://github.com/apache/spark/pull/20194#discussion_r160869162
  
    --- Diff: sql/catalyst/src/main/antlr4/org/apache/spark/sql/catalyst/parser/SqlBase.g4 ---
    @@ -141,7 +141,7 @@ statement
             (LIKE? pattern=STRING)?                                        #showTables
         | SHOW TABLE EXTENDED ((FROM | IN) db=identifier)?
             LIKE pattern=STRING partitionSpec?                             #showTable
    -    | SHOW DATABASES (LIKE pattern=STRING)?                            #showDatabases
    +    | SHOW DATABASES (LIKE? pattern=STRING)?                            #showDatabases
    --- End diff --
    
    No, I just saw like show tables like can be removed. so I think show databases like can also be removed. Just think it is removed, the operation is more convenient.


---

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


[GitHub] spark issue #20194: [SPARK-22999][SQL]'show databases like command' can remo...

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

    https://github.com/apache/spark/pull/20194
  
    **[Test build #86120 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/86120/testReport)** for PR 20194 at commit [`26e7c0d`](https://github.com/apache/spark/commit/26e7c0d22b07144502eb5e05343d6a78824a1f1b).
     * This patch passes all tests.
     * This patch merges cleanly.
     * This patch adds no public classes.


---

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


[GitHub] spark issue #20194: [SPARK-22999][SQL]'show databases like command' can remo...

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

    https://github.com/apache/spark/pull/20194
  
    cc @hvanhovell , too.


---

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


[GitHub] spark pull request #20194: [SPARK-22999][SQL]'show databases like command' c...

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

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


---

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


[GitHub] spark issue #20194: [SPARK-22999][SQL]'show databases like command' can remo...

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

    https://github.com/apache/spark/pull/20194
  
    LGTM
    
    Thanks! Merged to master/2.3


---

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


[GitHub] spark pull request #20194: [SPARK-22999][SQL]'show databases like command' c...

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

    https://github.com/apache/spark/pull/20194#discussion_r160867737
  
    --- Diff: sql/catalyst/src/main/antlr4/org/apache/spark/sql/catalyst/parser/SqlBase.g4 ---
    @@ -141,7 +141,7 @@ statement
             (LIKE? pattern=STRING)?                                        #showTables
         | SHOW TABLE EXTENDED ((FROM | IN) db=identifier)?
             LIKE pattern=STRING partitionSpec?                             #showTable
    -    | SHOW DATABASES (LIKE pattern=STRING)?                            #showDatabases
    +    | SHOW DATABASES (LIKE? pattern=STRING)?                            #showDatabases
    --- End diff --
    
    @guoxiaolongzte . MySQL also doesn't work like that. Do you have any reference for that syntax?


---

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