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

[GitHub] spark pull request #22421: [SPARK-25431][SQL][EXAMPLES] Fix function example...

GitHub user ueshin opened a pull request:

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

    [SPARK-25431][SQL][EXAMPLES] Fix function examples and unify the format of the example results.

    ## What changes were proposed in this pull request?
    
    There are some mistakes in examples of newly added functions. Also the format of the example results are not unified. We should fix and unify them.
    
    ## How was this patch tested?
    
    Manually executed the examples.


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

    $ git pull https://github.com/ueshin/apache-spark issues/SPARK-25431/fix_examples

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

    https://github.com/apache/spark/pull/22421.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 #22421
    
----
commit baed43acbe01e981ed5bc699285486bc25c9b3f8
Author: Takuya UESHIN <ue...@...>
Date:   2018-09-14T09:19:56Z

    Fix function examples and unify the format of the example results.

----


---

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


[GitHub] spark issue #22421: [SPARK-25431][SQL][EXAMPLES] Fix function examples and u...

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

    https://github.com/apache/spark/pull/22421
  
    If you don't mind, please revert this.
    cc @cloud-fan 


---

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


[GitHub] spark issue #22421: [SPARK-25431][SQL][EXAMPLES] Fix function examples and u...

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

    https://github.com/apache/spark/pull/22421
  
    @dongjoon-hyun I picked the string from `sql(...).show(truncate = false)` and modified a little. I'm sorry but I didn't notice that we use the `spark-sql` to pick the result. Let me send a follow-up pr.


---

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


[GitHub] spark pull request #22421: [SPARK-25431][SQL][EXAMPLES] Fix function example...

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/22421#discussion_r217795552
  
    --- Diff: sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/collectionOperations.scala ---
    @@ -718,7 +718,7 @@ case class MapConcat(children: Seq[Expression]) extends ComplexTypeMergingExpres
       examples = """
         Examples:
           > SELECT _FUNC_(array(struct(1, 'a'), struct(2, 'b')));
    -       {1:"a",2:"b"}
    +       [1 -> "a", 2 -> "b"]
    --- End diff --
    
    The previous one is correct.
    ```
    spark-sql> SELECT map_from_entries(array(struct(1, 'a'), struct(2, 'b')));
    {1:"a",2:"b"}
    ```


---

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


[GitHub] spark pull request #22421: [SPARK-25431][SQL][EXAMPLES] Fix function example...

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

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


---

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


[GitHub] spark issue #22421: [SPARK-25431][SQL][EXAMPLES] Fix function examples and u...

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

    https://github.com/apache/spark/pull/22421
  
    **[Test build #96069 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/96069/testReport)** for PR 22421 at commit [`baed43a`](https://github.com/apache/spark/commit/baed43acbe01e981ed5bc699285486bc25c9b3f8).


---

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


[GitHub] spark issue #22421: [SPARK-25431][SQL][EXAMPLES] Fix function examples and u...

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

    https://github.com/apache/spark/pull/22421
  
    Thank you, @ueshin .


---

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


[GitHub] spark issue #22421: [SPARK-25431][SQL][EXAMPLES] Fix function examples and u...

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

    https://github.com/apache/spark/pull/22421
  
    @ueshin . Could you revert the current one and send a new one please?


---

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


[GitHub] spark pull request #22421: [SPARK-25431][SQL][EXAMPLES] Fix function example...

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/22421#discussion_r217792214
  
    --- Diff: sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/collectionOperations.scala ---
    @@ -131,7 +131,7 @@ case class Size(child: Expression) extends UnaryExpression with ExpectsInputType
       examples = """
         Examples:
           > SELECT _FUNC_(map(1, 'a', 2, 'b'));
    -       [1,2]
    +       [1, 2]
    --- End diff --
    
    ?


---

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


[GitHub] spark issue #22421: [SPARK-25431][SQL][EXAMPLES] Fix function examples and u...

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

    https://github.com/apache/spark/pull/22421
  
    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 #22421: [SPARK-25431][SQL][EXAMPLES] Fix function examples and u...

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

    https://github.com/apache/spark/pull/22421
  
    @dongjoon-hyun Sure, reverted. Thanks!


---

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


[GitHub] spark issue #22421: [SPARK-25431][SQL][EXAMPLES] Fix function examples and u...

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

    https://github.com/apache/spark/pull/22421
  
    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 #22421: [SPARK-25431][SQL][EXAMPLES] Fix function examples and u...

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

    https://github.com/apache/spark/pull/22421
  
    **[Test build #96069 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/96069/testReport)** for PR 22421 at commit [`baed43a`](https://github.com/apache/spark/commit/baed43acbe01e981ed5bc699285486bc25c9b3f8).
     * 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 #22421: [SPARK-25431][SQL][EXAMPLES] Fix function examples and u...

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

    https://github.com/apache/spark/pull/22421
  
    @ueshin and @gatorsmile .
    
    Sorry, but could you explain where did you get the new result? IIRC, historically, the example illustrates the result from `spark-sql` like Hive description. The new change doesn't consistent to the master result.


---

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


[GitHub] spark issue #22421: [SPARK-25431][SQL][EXAMPLES] Fix function examples and u...

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

    https://github.com/apache/spark/pull/22421
  
    Test PASSed.
    Refer to this link for build results (access rights to CI server needed): 
    https://amplab.cs.berkeley.edu/jenkins//job/testing-k8s-prb-make-spark-distribution-unified/3110/
    Test PASSed.


---

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


[GitHub] spark issue #22421: [SPARK-25431][SQL][EXAMPLES] Fix function examples and u...

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

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


---

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