You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by OopsOutOfMemory <gi...@git.apache.org> on 2015/01/28 13:08:55 UTC

[GitHub] spark pull request: [SPARK-5324][SQL] Results of describe can't be...

GitHub user OopsOutOfMemory opened a pull request:

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

    [SPARK-5324][SQL] Results of describe can't be queried

    Make below code works.
    ```
    sql("DESCRIBE test").registerTempTable("describeTest")
    sql("SELECT * FROM describeTest").collect()
    ```

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

    $ git pull https://github.com/OopsOutOfMemory/spark desc_query

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

    https://github.com/apache/spark/pull/4249.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 #4249
    
----
commit 544573e7593c0df5630395cdd1725af2dfdb51ef
Author: OopsOutOfMemory <vi...@126.com>
Date:   2015-01-28T10:48:15Z

    initial

commit ac2c3bbc725266204dacb142fdb5cbcdf6783311
Author: OopsOutOfMemory <vi...@126.com>
Date:   2015-01-28T12:03:35Z

    refine code and test suite

----


---
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: [SPARK-5324][SQL] Results of describe can't be...

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

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


---
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: [SPARK-5324][SQL] Results of describe can't be...

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

    https://github.com/apache/spark/pull/4249#issuecomment-72874595
  
      [Test build #26754 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/26754/consoleFull) for   PR 4249 at commit [`3ba1058`](https://github.com/apache/spark/commit/3ba10580f9ba951a3e9627befdc6dd5408795b8c).
     * This patch merges cleanly.


---
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: [SPARK-5324][SQL] Results of describe can't be...

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

    https://github.com/apache/spark/pull/4249#issuecomment-73202635
  
      [Test build #26905 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/26905/consoleFull) for   PR 4249 at commit [`6fee13d`](https://github.com/apache/spark/commit/6fee13d3ecd70bab34c13514145a93d680947c09).
     * This patch **passes all tests**.
     * This patch merges cleanly.
     * This patch adds no public classes.


---
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: [SPARK-5324][SQL] Results of describe can't be...

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

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


---
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: [SPARK-5324][SQL] Results of describe can't be...

Posted by marmbrus <gi...@git.apache.org>.
Github user marmbrus commented on the pull request:

    https://github.com/apache/spark/pull/4249#issuecomment-73307633
  
    Thanks!  Merged to master and 1.3


---
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: [SPARK-5324][SQL] Results of describe can't be...

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

    https://github.com/apache/spark/pull/4249#discussion_r24062294
  
    --- Diff: sql/hive/src/test/scala/org/apache/spark/sql/hive/execution/HiveQuerySuite.scala ---
    @@ -63,6 +63,37 @@ class HiveQuerySuite extends HiveComparisonTest with BeforeAndAfter {
         }
       }
       
    +  test("SPARK-5324 Results of describe can't be queried") {
    --- End diff --
    
    that's a great idea


---
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: [SPARK-5324][SQL] Results of describe can't be...

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

    https://github.com/apache/spark/pull/4249#discussion_r23932721
  
    --- Diff: sql/hive/src/main/scala/org/apache/spark/sql/hive/HiveQl.scala ---
    @@ -54,13 +54,8 @@ private[hive] case object NativePlaceholder extends Command
      */
     case class DescribeCommand(
         table: LogicalPlan,
    -    isExtended: Boolean) extends Command {
    -  override def output = Seq(
    -    // Column names are based on Hive.
    -    AttributeReference("col_name", StringType, nullable = false)(),
    -    AttributeReference("data_type", StringType, nullable = false)(),
    -    AttributeReference("comment", StringType, nullable = false)())
    -}
    +    override val output: Seq[Attribute],
    --- End diff --
    
    yeah, if we need every operator can be queried like a table, we need make it as a default argument, but does it break the current api or interface ? Shall we do it in another PR or file a separated JIAR?


---
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: [SPARK-5324][SQL] Results of describe can't be...

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

    https://github.com/apache/spark/pull/4249#issuecomment-73195127
  
      [Test build #26905 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/26905/consoleFull) for   PR 4249 at commit [`6fee13d`](https://github.com/apache/spark/commit/6fee13d3ecd70bab34c13514145a93d680947c09).
     * This patch merges cleanly.


---
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: [SPARK-5324][SQL] Results of describe can't be...

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

    https://github.com/apache/spark/pull/4249#discussion_r24126304
  
    --- Diff: sql/hive/src/main/scala/org/apache/spark/sql/hive/HiveQl.scala ---
    @@ -55,13 +55,11 @@ private[hive] case object NativePlaceholder extends Command
      */
     case class DescribeCommand(
         table: LogicalPlan,
    -    isExtended: Boolean) extends Command {
    -  override def output = Seq(
    -    // Column names are based on Hive.
    -    AttributeReference("col_name", StringType, nullable = false)(),
    -    AttributeReference("data_type", StringType, nullable = false)(),
    -    AttributeReference("comment", StringType, nullable = false)())
    -}
    +    override val output: Seq[Attribute] =
    +      Seq(AttributeReference("col_name", StringType, nullable = false)(),
    +        AttributeReference("data_type", StringType, nullable = false)(),
    +        AttributeReference("comment", StringType, nullable = false)()),
    +    isExtended: Boolean) extends Command
    --- End diff --
    
    Hmm, i guess that is okay for leaf nodes since they will never be copied...


---
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: [SPARK-5324][SQL] Results of describe can't be...

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

    https://github.com/apache/spark/pull/4249#discussion_r23970344
  
    --- Diff: sql/hive/src/main/scala/org/apache/spark/sql/hive/HiveQl.scala ---
    @@ -54,13 +54,8 @@ private[hive] case object NativePlaceholder extends Command
      */
     case class DescribeCommand(
         table: LogicalPlan,
    -    isExtended: Boolean) extends Command {
    -  override def output = Seq(
    -    // Column names are based on Hive.
    -    AttributeReference("col_name", StringType, nullable = false)(),
    -    AttributeReference("data_type", StringType, nullable = false)(),
    -    AttributeReference("comment", StringType, nullable = false)())
    -}
    +    override val output: Seq[Attribute],
    --- End diff --
    
    This is an internal API so we can change it.  I'd just do it now.


---
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: [SPARK-5324][SQL] Results of describe can't be...

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

    https://github.com/apache/spark/pull/4249#issuecomment-71825690
  
    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 pull request: [SPARK-5324][SQL] Results of describe can't be...

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

    https://github.com/apache/spark/pull/4249#issuecomment-73013081
  
      [Test build #26831 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/26831/consoleFull) for   PR 4249 at commit [`e71430a`](https://github.com/apache/spark/commit/e71430a5709836e74556713ec5644f54abc032f9).
     * This patch **passes all tests**.
     * This patch merges cleanly.
     * This patch adds no public classes.


---
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: [SPARK-5324][SQL] Results of describe can't be...

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

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


---
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: [SPARK-5324][SQL] Results of describe can't be...

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

    https://github.com/apache/spark/pull/4249#issuecomment-72484897
  
      [Test build #26519 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/26519/consoleFull) for   PR 4249 at commit [`354ad71`](https://github.com/apache/spark/commit/354ad715a82acb54d1bc6def314f75ef7d55b1f4).
     * This patch merges cleanly.


---
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: [SPARK-5324][SQL] Results of describe can't be...

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

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


---
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: [SPARK-5324][SQL] Results of describe can't be...

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

    https://github.com/apache/spark/pull/4249#issuecomment-72404020
  
      [Test build #26485 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/26485/consoleFull) for   PR 4249 at commit [`11559ae`](https://github.com/apache/spark/commit/11559ae5b8356e0b50b1647af1623b04ca42523a).
     * This patch **passes all tests**.
     * This patch merges cleanly.
     * This patch adds no public classes.


---
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: [SPARK-5324][SQL] Results of describe can't be...

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

    https://github.com/apache/spark/pull/4249#issuecomment-72497469
  
      [Test build #26518 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/26518/consoleFull) for   PR 4249 at commit [`d541a35`](https://github.com/apache/spark/commit/d541a3508f296b53dc354e3a309ca15e5bfcc473).
     * This patch **passes all tests**.
     * This patch merges cleanly.
     * This patch adds no public classes.


---
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: [SPARK-5324][SQL] Results of describe can't be...

Posted by OopsOutOfMemory <gi...@git.apache.org>.
Github user OopsOutOfMemory commented on the pull request:

    https://github.com/apache/spark/pull/4249#issuecomment-71825463
  
    /cc @marmbrus


---
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: [SPARK-5324][SQL] Results of describe can't be...

Posted by marmbrus <gi...@git.apache.org>.
Github user marmbrus commented on the pull request:

    https://github.com/apache/spark/pull/4249#issuecomment-72400392
  
    ok to test


---
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: [SPARK-5324][SQL] Results of describe can't be...

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

    https://github.com/apache/spark/pull/4249#discussion_r23812908
  
    --- Diff: sql/hive/src/test/scala/org/apache/spark/sql/hive/execution/HiveQuerySuite.scala ---
    @@ -56,13 +56,44 @@ class HiveQuerySuite extends HiveComparisonTest with BeforeAndAfter {
         Locale.setDefault(originalLocale)
       }
     
    -  test("SPARK-4908: concurent hive native commands") {
    +  test("SPARK-4908: concurrent hive native commands") {
         (1 to 100).par.map { _ =>
           sql("USE default")
           sql("SHOW TABLES")
         }
       }
       
    +  test("SPARK-5324 query result of describe command") {
    +    loadTestTable("src")
    +    
    +    // register a describe command to be a temp table
    +    sql("desc src").registerTempTable("mydesc")
    +    assertResult(
    +      Array(
    +        Row("col_name", "StringType", null),
    +        Row("data_type", "StringType", null),
    +        Row("comment", "StringType", null)
    +      )) {
    +      sql("desc mydesc").collect()
    --- End diff --
    
    Use `checkAnswer` for test that check the results of queries.


---
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: [SPARK-5324][SQL] Results of describe can't be...

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

    https://github.com/apache/spark/pull/4249#discussion_r23812967
  
    --- Diff: sql/hive/src/main/scala/org/apache/spark/sql/hive/HiveQl.scala ---
    @@ -54,13 +54,8 @@ private[hive] case object NativePlaceholder extends Command
      */
     case class DescribeCommand(
         table: LogicalPlan,
    -    isExtended: Boolean) extends Command {
    -  override def output = Seq(
    -    // Column names are based on Hive.
    -    AttributeReference("col_name", StringType, nullable = false)(),
    -    AttributeReference("data_type", StringType, nullable = false)(),
    -    AttributeReference("comment", StringType, nullable = false)())
    -}
    +    override val output: Seq[Attribute],
    --- End diff --
    
    Maybe the references should be a default argument instead so they are defined with the operator.


---
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: [SPARK-5324][SQL] Results of describe can't be...

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

    https://github.com/apache/spark/pull/4249#issuecomment-72483969
  
      [Test build #26518 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/26518/consoleFull) for   PR 4249 at commit [`d541a35`](https://github.com/apache/spark/commit/d541a3508f296b53dc354e3a309ca15e5bfcc473).
     * This patch merges cleanly.


---
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: [SPARK-5324][SQL] Results of describe can't be...

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

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


---
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: [SPARK-5324][SQL] Results of describe can't be...

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

    https://github.com/apache/spark/pull/4249#issuecomment-72888527
  
      [Test build #26754 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/26754/consoleFull) for   PR 4249 at commit [`3ba1058`](https://github.com/apache/spark/commit/3ba10580f9ba951a3e9627befdc6dd5408795b8c).
     * This patch **passes all tests**.
     * This patch merges cleanly.
     * This patch adds no public classes.


---
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: [SPARK-5324][SQL] Results of describe can't be...

Posted by OopsOutOfMemory <gi...@git.apache.org>.
Github user OopsOutOfMemory commented on the pull request:

    https://github.com/apache/spark/pull/4249#issuecomment-73064648
  
    @marmbrus is this ready to go ?


---
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: [SPARK-5324][SQL] Results of describe can't be...

Posted by OopsOutOfMemory <gi...@git.apache.org>.
Github user OopsOutOfMemory commented on the pull request:

    https://github.com/apache/spark/pull/4249#issuecomment-72875605
  
    /cc @marmbrus 
    make the references as default argument.


---
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: [SPARK-5324][SQL] Results of describe can't be...

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

    https://github.com/apache/spark/pull/4249#issuecomment-72400616
  
      [Test build #26485 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/26485/consoleFull) for   PR 4249 at commit [`11559ae`](https://github.com/apache/spark/commit/11559ae5b8356e0b50b1647af1623b04ca42523a).
     * This patch merges cleanly.


---
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: [SPARK-5324][SQL] Results of describe can't be...

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

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


---
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: [SPARK-5324][SQL] Results of describe can't be...

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

    https://github.com/apache/spark/pull/4249#issuecomment-73006084
  
      [Test build #26831 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/26831/consoleFull) for   PR 4249 at commit [`e71430a`](https://github.com/apache/spark/commit/e71430a5709836e74556713ec5644f54abc032f9).
     * This patch merges cleanly.


---
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: [SPARK-5324][SQL] Results of describe can't be...

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

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


---
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: [SPARK-5324][SQL] Results of describe can't be...

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

    https://github.com/apache/spark/pull/4249#discussion_r24126170
  
    --- Diff: sql/hive/src/test/scala/org/apache/spark/sql/hive/execution/HiveOperatorQueryableSuite.scala ---
    @@ -0,0 +1,48 @@
    +/*
    + * Licensed to the Apache Software Foundation (ASF) under one or more
    + * contributor license agreements.  See the NOTICE file distributed with
    + * this work for additional information regarding copyright ownership.
    + * The ASF licenses this file to You under the Apache License, Version 2.0
    + * (the "License"); you may not use this file except in compliance with
    + * the License.  You may obtain a copy of the License at
    + *
    + *    http://www.apache.org/licenses/LICENSE-2.0
    + *
    + * Unless required by applicable law or agreed to in writing, software
    + * distributed under the License is distributed on an "AS IS" BASIS,
    + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    + * See the License for the specific language governing permissions and
    + * limitations under the License.
    + */
    +
    +package org.apache.spark.sql.hive.execution
    +
    +import org.apache.spark.sql.{Row, QueryTest}
    +import org.apache.spark.sql.hive.test.TestHive._
    +
    +/**
    + * A set of tests that validates commands can also be queried by like a table
    + */
    +class HiveOperatorQueryableSuite extends QueryTest {
    +  test("SPARK-5324 query result of describe command") {
    +    loadTestTable("src")
    +
    +    // register a describe command to be a temp table
    +    sql("desc src").registerTempTable("mydesc")
    +    checkAnswer(
    +      sql("desc mydesc"),
    +      Seq(Row("col_name", "StringType", null),
    +        Row("data_type", "StringType", null),
    +        Row("comment", "StringType", null)))
    --- End diff --
    
    Nit: usually we prefer
    
    ```
    Seq(
      Row(...),
      ...
      Row(...))
    ```


---
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: [SPARK-5324][SQL] Results of describe can't be...

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

    https://github.com/apache/spark/pull/4249#discussion_r24126016
  
    --- Diff: sql/hive/src/main/scala/org/apache/spark/sql/hive/HiveQl.scala ---
    @@ -55,13 +55,11 @@ private[hive] case object NativePlaceholder extends Command
      */
     case class DescribeCommand(
         table: LogicalPlan,
    -    isExtended: Boolean) extends Command {
    -  override def output = Seq(
    -    // Column names are based on Hive.
    -    AttributeReference("col_name", StringType, nullable = false)(),
    -    AttributeReference("data_type", StringType, nullable = false)(),
    -    AttributeReference("comment", StringType, nullable = false)())
    -}
    +    override val output: Seq[Attribute] =
    +      Seq(AttributeReference("col_name", StringType, nullable = false)(),
    +        AttributeReference("data_type", StringType, nullable = false)(),
    +        AttributeReference("comment", StringType, nullable = false)()),
    +    isExtended: Boolean) extends Command
    --- End diff --
    
    I think it's OK to just change the `def` to a `val` without moving `output` into constructor argument list, so that we don't have to use named parameter `isExtended = ...` elsewhere. Did I miss something here?


---
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: [SPARK-5324][SQL] Results of describe can't be...

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

    https://github.com/apache/spark/pull/4249#discussion_r23696141
  
    --- Diff: sql/hive/src/test/scala/org/apache/spark/sql/hive/execution/HiveQuerySuite.scala ---
    @@ -63,6 +63,37 @@ class HiveQuerySuite extends HiveComparisonTest with BeforeAndAfter {
         }
       }
       
    +  test("SPARK-5324 Results of describe can't be queried") {
    --- End diff --
    
    nit: I'd prefer that the test name said what the *correct* behavior is, rather than the old bug it is checking for.  I think its better when we're looking at test output, or if there is a regression on this and a dev needs to figure out what is being tests.
    
    Maybe I am wrong about this, though -- we haven't applied that universally so far


---
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: [SPARK-5324][SQL] Results of describe can't be...

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

    https://github.com/apache/spark/pull/4249#issuecomment-72498275
  
      [Test build #26519 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/26519/consoleFull) for   PR 4249 at commit [`354ad71`](https://github.com/apache/spark/commit/354ad715a82acb54d1bc6def314f75ef7d55b1f4).
     * This patch **passes all tests**.
     * This patch merges cleanly.
     * This patch adds no public classes.


---
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