You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2020/06/29 06:16:10 UTC

[GitHub] [spark] xianyinxin opened a new pull request #28943: SPARK-32127: Check rules for MERGE INTO should use MergeAction.conditition other than MergeAction.children

xianyinxin opened a new pull request #28943:
URL: https://github.com/apache/spark/pull/28943


   
   ### What changes were proposed in this pull request?
   
   This pr fix a bug of check rules for MERGE INTO.
   
   ### Why are the changes needed?
   
   SPARK-30924 adds some check rules for MERGE INTO one of which ensures the first MATCHED clause must have a condition. However, it uses `MergeAction.children` in the checking which is not accurate for the case, and it lets the below case pass the check:
   
   ```
   MERGE INTO testcat1.ns1.ns2.tbl AS target
   xxx
   WHEN MATCHED THEN UPDATE SET target.col2 = source.col2
   WHEN MATCHED THEN DELETE
   xxx
   ```
   
   We should use `MergeAction.condition` instead.
   
   
   ### Does this PR introduce _any_ user-facing change?
   
   No
   
   
   ### How was this patch tested?
   
   An existed ut is modified.
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



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


[GitHub] [spark] AmplabJenkins commented on pull request #28943: [SPARK-32127][SQL]: Check rules for MERGE INTO should use MergeAction.conditition other than MergeAction.children

Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #28943:
URL: https://github.com/apache/spark/pull/28943#issuecomment-651124304






----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



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


[GitHub] [spark] AmplabJenkins commented on pull request #28943: [SPARK-32127][SQL]: Check rules for MERGE INTO should use MergeAction.conditition other than MergeAction.children

Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #28943:
URL: https://github.com/apache/spark/pull/28943#issuecomment-650980953






----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



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


[GitHub] [spark] SparkQA commented on pull request #28943: [SPARK-32127][SQL]: Check rules for MERGE INTO should use MergeAction.conditition other than MergeAction.children

Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #28943:
URL: https://github.com/apache/spark/pull/28943#issuecomment-650986554


   **[Test build #124626 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/124626/testReport)** for PR 28943 at commit [`d02cef2`](https://github.com/apache/spark/commit/d02cef20deb1182ff1ac42a2e8cb7e1ce30b5b13).


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



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


[GitHub] [spark] SparkQA removed a comment on pull request #28943: [SPARK-32127][SQL]: Check rules for MERGE INTO should use MergeAction.conditition other than MergeAction.children

Posted by GitBox <gi...@apache.org>.
SparkQA removed a comment on pull request #28943:
URL: https://github.com/apache/spark/pull/28943#issuecomment-650986554


   **[Test build #124626 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/124626/testReport)** for PR 28943 at commit [`d02cef2`](https://github.com/apache/spark/commit/d02cef20deb1182ff1ac42a2e8cb7e1ce30b5b13).


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



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


[GitHub] [spark] SparkQA commented on pull request #28943: [SPARK-32127][SQL]: Check rules for MERGE INTO should use MergeAction.conditition other than MergeAction.children

Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #28943:
URL: https://github.com/apache/spark/pull/28943#issuecomment-651091012


   **[Test build #124626 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/124626/testReport)** for PR 28943 at commit [`d02cef2`](https://github.com/apache/spark/commit/d02cef20deb1182ff1ac42a2e8cb7e1ce30b5b13).
    * This patch passes all tests.
    * This patch merges cleanly.
    * This patch adds the following public classes _(experimental)_:
     * `sealed abstract class MergeAction extends Expression with Unevaluable `
     * `case class DeleteAction(condition: Option[Expression]) extends MergeAction`


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



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


[GitHub] [spark] xianyinxin commented on pull request #28943: [SPARK-32127][SQL]: Check rules for MERGE INTO should use MergeAction.conditition other than MergeAction.children

Posted by GitBox <gi...@apache.org>.
xianyinxin commented on pull request #28943:
URL: https://github.com/apache/spark/pull/28943#issuecomment-651465152


   Thanks @cloud-fan !


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



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


[GitHub] [spark] AmplabJenkins removed a comment on pull request #28943: [SPARK-32127][SQL]: Check rules for MERGE INTO should use MergeAction.conditition other than MergeAction.children

Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #28943:
URL: https://github.com/apache/spark/pull/28943#issuecomment-651124304






----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



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


[GitHub] [spark] AmplabJenkins removed a comment on pull request #28943: [SPARK-32127][SQL]: Check rules for MERGE INTO should use MergeAction.conditition other than MergeAction.children

Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #28943:
URL: https://github.com/apache/spark/pull/28943#issuecomment-650980953






----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



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


[GitHub] [spark] cloud-fan closed pull request #28943: [SPARK-32127][SQL]: Check rules for MERGE INTO should use MergeAction.conditition other than MergeAction.children

Posted by GitBox <gi...@apache.org>.
cloud-fan closed pull request #28943:
URL: https://github.com/apache/spark/pull/28943


   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



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


[GitHub] [spark] cloud-fan commented on pull request #28943: [SPARK-32127][SQL]: Check rules for MERGE INTO should use MergeAction.conditition other than MergeAction.children

Posted by GitBox <gi...@apache.org>.
cloud-fan commented on pull request #28943:
URL: https://github.com/apache/spark/pull/28943#issuecomment-651113991


   thanks, merging to 3.0!


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



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


[GitHub] [spark] xianyinxin commented on pull request #28943: [SPARK-32127][SQL]: Check rules for MERGE INTO should use MergeAction.conditition other than MergeAction.children

Posted by GitBox <gi...@apache.org>.
xianyinxin commented on pull request #28943:
URL: https://github.com/apache/spark/pull/28943#issuecomment-650947651


   @cloud-fan @brkyvz , pls take a look.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



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