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 2022/03/26 03:12:16 UTC

[GitHub] [spark] beliefer opened a new pull request #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

beliefer opened a new pull request #32477:
URL: https://github.com/apache/spark/pull/32477


   ### What changes were proposed in this pull request?
   `ANSI SQL: SIMILAR TO ... ESCAPE` is very useful.
   There are some mainstream database support the syntax.
   **PostgreSQL**:
   https://www.postgresql.org/docs/current/functions-matching.html#FUNCTIONS-SIMILARTO-REGEXP
   
   **Redshift**:
   https://docs.aws.amazon.com/redshift/latest/dg/pattern-matching-conditions-similar-to.html
   
   **Sybase**:
   http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.help.sqlanywhere.12.0.0/dbreference/like-regexp-similarto.html
   
   **Firebird**:
   http://firebirdsql.org/file/documentation/html/en/refdocs/fblangref25/firebird-25-language-reference.html#fblangref25-commons-predsiimilarto
   
   This util supports the following pattern-matching metacharacters:
   
   Operator | Description
   -- | --
   % | Matches any sequence of zero or more characters.
   _ | Matches any single character.
   \| | Denotes alternation (either of two alternatives).
   \* | Repeat the previous item zero or more times.
   \+ | Repeat the previous item one or more times.
   ? | Repeat the previous item zero or one time.
   {m} | Repeat the previous item exactly m times.
   {m,} | Repeat the previous item m or more times.
   {m,n} | Repeat the previous item at least m and not more than n times.
   () | Parentheses group items into a single logical item.
   [...] | A bracket expression specifies a character class, just as in POSIX regular expressions.
   
   **Note**
   `SIMILAR TO` is similar to `RLIKE`, but with the following differences:
          1. The `SIMILAR TO` operator returns true only if its pattern matches the entire string,
             unlike `RLIKE` behavior, where the pattern can match any portion of the string.
          2. The regex string allow use _ and % as wildcard characters denoting any single character
             and any string, respectively (these are comparable to . and .* in POSIX regular
             expressions).
          3. The regex string allow use escape character like `LIKE` behavior.
          4. '.', '^' and '$' is not a meta character for `SIMILAR TO`.
   
   ### Why are the changes needed?
   `ANSI SQL: SIMILAR TO ... ESCAPE` is very useful.
   
   
   ### Does this PR introduce _any_ user-facing change?
   Yes, a new feature.
   
   
   ### How was this patch tested?
   New tests
   


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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] beliefer commented on pull request #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   ping @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] SparkQA commented on pull request #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   **[Test build #138284 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/138284/testReport)** for PR 32477 at commit [`1363fb5`](https://github.com/apache/spark/commit/1363fb5c473a9d3f15d829f029432e8f8a1ab30d).


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/50680/
   


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   Kubernetes integration test status failure
   URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/50656/
   


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/146183/
   


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/50663/
   


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/42807/
   


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   **[Test build #139477 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/139477/testReport)** for PR 32477 at commit [`29e5822`](https://github.com/apache/spark/commit/29e582272facf7c16acc1e45a7b363c40a29e540).


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/42807/
   


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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






-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/146188/
   


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/146188/
   


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/44000/
   


-- 
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] github-actions[bot] commented on pull request #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on pull request #32477:
URL: https://github.com/apache/spark/pull/32477#issuecomment-1079529509


   We're closing this PR because it hasn't been updated in a while. This isn't a judgement on the merit of the PR in any way. It's just a way of keeping the PR queue manageable.
   If you'd like to revive this PR, please reopen it and ask a committer to remove the Stale tag!


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/138284/
   


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   Kubernetes integration test starting
   URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/47348/
   


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/42806/
   


-- 
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] github-actions[bot] closed pull request #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

Posted by GitBox <gi...@apache.org>.
github-actions[bot] closed pull request #32477:
URL: https://github.com/apache/spark/pull/32477


   


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/139477/
   


-- 
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] beliefer commented on a change in pull request #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

Posted by GitBox <gi...@apache.org>.
beliefer commented on a change in pull request #32477:
URL: https://github.com/apache/spark/pull/32477#discussion_r632423582



##########
File path: sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/util/StringUtils.scala
##########
@@ -66,6 +67,52 @@ object StringUtils extends Logging {
     "(?s)" + out.result() // (?s) enables dotall mode, causing "." to match new lines
   }
 
+  /**
+   * Validate and convert SQL 'similar to' pattern to a Java regular expression.
+   *
+   * This function is similar to escapeLikeRegex, but there are some differences as follows:
+   * 1. If the escape character precedes the meta character for SIMILAR TO, the meta character
+   *    should convert to quote literal.
+   * 2. If '\' is not escape character, need convert to quote literal.
+   * 3. '.', '^' and '$' is not a meta character for SIMILAR TO,
+   *    so we need convert it to quote literal.
+   * 4. Avoid convert the characters of Java regular expression to quote literal.
+   * @param pattern the SQL pattern to convert
+   * @param escapeChar the escape character.
+   * @return the equivalent Java regular expression of the pattern for SIMILAR TO
+   */
+  def escapeSimilarRegex(pattern: String, escapeChar: Char): String = {

Review comment:
       escapeLikeRegex produces the_regex
   escapeSimilarRegex produces ^the_regex$




-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   **[Test build #146188 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/146188/testReport)** for PR 32477 at commit [`29e5822`](https://github.com/apache/spark/commit/29e582272facf7c16acc1e45a7b363c40a29e540).


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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] beliefer commented on pull request #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   retest this please


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/50656/
   


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   **[Test build #139477 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/139477/testReport)** for PR 32477 at commit [`29e5822`](https://github.com/apache/spark/commit/29e582272facf7c16acc1e45a7b363c40a29e540).
    * This patch passes all tests.
    * This patch merges cleanly.
    * This patch adds no public classes.


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   Kubernetes integration test starting
   URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/43986/
   


-- 
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] beliefer commented on pull request #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   retest this please


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   Kubernetes integration test status failure
   URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/47348/
   


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   Kubernetes integration test starting
   URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/50656/
   


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   **[Test build #146206 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/146206/testReport)** for PR 32477 at commit [`29e5822`](https://github.com/apache/spark/commit/29e582272facf7c16acc1e45a7b363c40a29e540).


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   **[Test build #146206 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/146206/testReport)** for PR 32477 at commit [`29e5822`](https://github.com/apache/spark/commit/29e582272facf7c16acc1e45a7b363c40a29e540).


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   Kubernetes integration test starting
   URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/50680/
   


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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] github-actions[bot] closed pull request #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

Posted by GitBox <gi...@apache.org>.
github-actions[bot] closed pull request #32477:
URL: https://github.com/apache/spark/pull/32477


   


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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] github-actions[bot] commented on pull request #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on pull request #32477:
URL: https://github.com/apache/spark/pull/32477#issuecomment-991385630


   We're closing this PR because it hasn't been updated in a while. This isn't a judgement on the merit of the PR in any way. It's just a way of keeping the PR queue manageable.
   If you'd like to revive this PR, please reopen it and ask a committer to remove the Stale tag!


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/138285/
   


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/139468/
   


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   Kubernetes integration test starting
   URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/50663/
   


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   Kubernetes integration test status failure
   URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/50663/
   


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   **[Test build #138285 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/138285/testReport)** for PR 32477 at commit [`cd8d9f7`](https://github.com/apache/spark/commit/cd8d9f7dc08721b77274ea21f38d3302b49f3dea).


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   **[Test build #138284 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/138284/testReport)** for PR 32477 at commit [`1363fb5`](https://github.com/apache/spark/commit/1363fb5c473a9d3f15d829f029432e8f8a1ab30d).


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   **[Test build #139468 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/139468/testReport)** for PR 32477 at commit [`29e5822`](https://github.com/apache/spark/commit/29e582272facf7c16acc1e45a7b363c40a29e540).


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   **[Test build #139465 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/139465/testReport)** for PR 32477 at commit [`788dfe0`](https://github.com/apache/spark/commit/788dfe0b103367e52d3ca8ed42e227c06116f244).


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/47348/
   


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   **[Test build #139463 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/139463/testReport)** for PR 32477 at commit [`71f6d95`](https://github.com/apache/spark/commit/71f6d9541f8ae72f019c6d096f597b0197e6e6e6).


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   **[Test build #146188 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/146188/testReport)** for PR 32477 at commit [`29e5822`](https://github.com/apache/spark/commit/29e582272facf7c16acc1e45a7b363c40a29e540).
    * This patch **fails PySpark unit tests**.
    * This patch merges cleanly.
    * This patch adds no public classes.


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/146183/
   


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   Kubernetes integration test status success
   URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/44000/
   


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   **[Test build #139465 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/139465/testReport)** for PR 32477 at commit [`788dfe0`](https://github.com/apache/spark/commit/788dfe0b103367e52d3ca8ed42e227c06116f244).


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/139463/
   


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   Kubernetes integration test starting
   URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/42807/
   


-- 
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] beliefer commented on a change in pull request #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

Posted by GitBox <gi...@apache.org>.
beliefer commented on a change in pull request #32477:
URL: https://github.com/apache/spark/pull/32477#discussion_r632423582



##########
File path: sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/util/StringUtils.scala
##########
@@ -66,6 +67,52 @@ object StringUtils extends Logging {
     "(?s)" + out.result() // (?s) enables dotall mode, causing "." to match new lines
   }
 
+  /**
+   * Validate and convert SQL 'similar to' pattern to a Java regular expression.
+   *
+   * This function is similar to escapeLikeRegex, but there are some differences as follows:
+   * 1. If the escape character precedes the meta character for SIMILAR TO, the meta character
+   *    should convert to quote literal.
+   * 2. If '\' is not escape character, need convert to quote literal.
+   * 3. '.', '^' and '$' is not a meta character for SIMILAR TO,
+   *    so we need convert it to quote literal.
+   * 4. Avoid convert the characters of Java regular expression to quote literal.
+   * @param pattern the SQL pattern to convert
+   * @param escapeChar the escape character.
+   * @return the equivalent Java regular expression of the pattern for SIMILAR TO
+   */
+  def escapeSimilarRegex(pattern: String, escapeChar: Char): String = {

Review comment:
       `escapeLikeRegex` produces `the_regex`
   `escapeSimilarRegex` produces `^the_regex$`




-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   **[Test build #139468 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/139468/testReport)** for PR 32477 at commit [`29e5822`](https://github.com/apache/spark/commit/29e582272facf7c16acc1e45a7b363c40a29e540).


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   Kubernetes integration test starting
   URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/43988/
   


-- 
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] beliefer commented on pull request #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   ping @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.

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/139468/
   


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   **[Test build #138284 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/138284/testReport)** for PR 32477 at commit [`1363fb5`](https://github.com/apache/spark/commit/1363fb5c473a9d3f15d829f029432e8f8a1ab30d).
    * This patch **fails Scala style tests**.
    * This patch merges cleanly.
    * This patch adds no public classes.


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   Kubernetes integration test status failure
   URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/42807/
   


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   **[Test build #139465 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/139465/testReport)** for PR 32477 at commit [`788dfe0`](https://github.com/apache/spark/commit/788dfe0b103367e52d3ca8ed42e227c06116f244).
    * This patch **fails Spark unit tests**.
    * This patch merges cleanly.
    * This patch adds no public classes.


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/139463/
   


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   Kubernetes integration test status failure
   URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/43986/
   


-- 
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] beliefer closed pull request #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

Posted by GitBox <gi...@apache.org>.
beliefer closed pull request #32477:
URL: https://github.com/apache/spark/pull/32477


   


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   **[Test build #146188 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/146188/testReport)** for PR 32477 at commit [`29e5822`](https://github.com/apache/spark/commit/29e582272facf7c16acc1e45a7b363c40a29e540).


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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] beliefer closed pull request #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

Posted by GitBox <gi...@apache.org>.
beliefer closed pull request #32477:
URL: https://github.com/apache/spark/pull/32477


   


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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] github-actions[bot] commented on pull request #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on pull request #32477:
URL: https://github.com/apache/spark/pull/32477#issuecomment-991385630


   We're closing this PR because it hasn't been updated in a while. This isn't a judgement on the merit of the PR in any way. It's just a way of keeping the PR queue manageable.
   If you'd like to revive this PR, please reopen it and ask a committer to remove the Stale tag!


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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] github-actions[bot] closed pull request #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

Posted by GitBox <gi...@apache.org>.
github-actions[bot] closed pull request #32477:
URL: https://github.com/apache/spark/pull/32477


   


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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] beliefer commented on pull request #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   @cloud-fan Please help me to remove stale label.


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/138284/
   


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/138285/
   


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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






-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


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


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/139477/
   


-- 
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] beliefer commented on pull request #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   @cloud-fan Please help me to remove stale label.


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/146206/
   


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   **[Test build #146183 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/146183/testReport)** for PR 32477 at commit [`29e5822`](https://github.com/apache/spark/commit/29e582272facf7c16acc1e45a7b363c40a29e540).
    * This patch **fails Spark unit tests**.
    * This patch merges cleanly.
    * This patch adds no public classes.


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   **[Test build #146183 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/146183/testReport)** for PR 32477 at commit [`29e5822`](https://github.com/apache/spark/commit/29e582272facf7c16acc1e45a7b363c40a29e540).


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 a change in pull request #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

Posted by GitBox <gi...@apache.org>.
cloud-fan commented on a change in pull request #32477:
URL: https://github.com/apache/spark/pull/32477#discussion_r631990533



##########
File path: sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/util/StringUtils.scala
##########
@@ -66,6 +67,52 @@ object StringUtils extends Logging {
     "(?s)" + out.result() // (?s) enables dotall mode, causing "." to match new lines
   }
 
+  /**
+   * Validate and convert SQL 'similar to' pattern to a Java regular expression.
+   *
+   * This function is similar to escapeLikeRegex, but there are some differences as follows:
+   * 1. If the escape character precedes the meta character for SIMILAR TO, the meta character
+   *    should convert to quote literal.
+   * 2. If '\' is not escape character, need convert to quote literal.
+   * 3. '.', '^' and '$' is not a meta character for SIMILAR TO,
+   *    so we need convert it to quote literal.
+   * 4. Avoid convert the characters of Java regular expression to quote literal.
+   * @param pattern the SQL pattern to convert
+   * @param escapeChar the escape character.
+   * @return the equivalent Java regular expression of the pattern for SIMILAR TO
+   */
+  def escapeSimilarRegex(pattern: String, escapeChar: Char): String = {

Review comment:
       Is it possible to share some code with `escapeLikeRegex`? It seems like the only difference is, let's say `escapeLikeRegex` produces `^the_regex`, and `escapeSimilarRegex` should produce `^the_regex$`




-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/44000/
   


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   **[Test build #139468 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/139468/testReport)** for PR 32477 at commit [`29e5822`](https://github.com/apache/spark/commit/29e582272facf7c16acc1e45a7b363c40a29e540).
    * This patch passes all tests.
    * This patch merges cleanly.
    * This patch adds no public classes.


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   Kubernetes integration test status failure
   URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/43988/
   


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/43986/
   


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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






-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/47348/
   


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   **[Test build #139463 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/139463/testReport)** for PR 32477 at commit [`71f6d95`](https://github.com/apache/spark/commit/71f6d9541f8ae72f019c6d096f597b0197e6e6e6).


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   **[Test build #146206 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/146206/testReport)** for PR 32477 at commit [`29e5822`](https://github.com/apache/spark/commit/29e582272facf7c16acc1e45a7b363c40a29e540).
    * This patch passes all tests.
    * This patch merges cleanly.
    * This patch adds no public classes.


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/146206/
   


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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] beliefer commented on pull request #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   @cloud-fan Please help me to remove stale label.


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   **[Test build #146183 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/146183/testReport)** for PR 32477 at commit [`29e5822`](https://github.com/apache/spark/commit/29e582272facf7c16acc1e45a7b363c40a29e540).


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/50656/
   


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/50663/
   


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/42806/
   


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   Kubernetes integration test starting
   URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/44000/
   


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   **[Test build #139477 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/139477/testReport)** for PR 32477 at commit [`29e5822`](https://github.com/apache/spark/commit/29e582272facf7c16acc1e45a7b363c40a29e540).


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   **[Test build #138285 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/138285/testReport)** for PR 32477 at commit [`cd8d9f7`](https://github.com/apache/spark/commit/cd8d9f7dc08721b77274ea21f38d3302b49f3dea).


-- 
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] beliefer closed pull request #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

Posted by GitBox <gi...@apache.org>.
beliefer closed pull request #32477:
URL: https://github.com/apache/spark/pull/32477


   


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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] beliefer commented on pull request #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   retest this please


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   Kubernetes integration test status failure
   URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/50680/
   


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/50680/
   


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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] beliefer commented on pull request #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   ping @MaxGekk cc @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.

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/43986/
   


-- 
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 #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

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


   **[Test build #139463 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/139463/testReport)** for PR 32477 at commit [`71f6d95`](https://github.com/apache/spark/commit/71f6d9541f8ae72f019c6d096f597b0197e6e6e6).
    * This patch **fails Scala style tests**.
    * This patch merges cleanly.
    * This patch adds no public classes.


-- 
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] beliefer commented on a change in pull request #32477: [SPARK-35348][SQL] Support the utils for escapse the regex for ANSI SQL: SIMILAR TO … ESCAPE syntax

Posted by GitBox <gi...@apache.org>.
beliefer commented on a change in pull request #32477:
URL: https://github.com/apache/spark/pull/32477#discussion_r632423582



##########
File path: sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/util/StringUtils.scala
##########
@@ -66,6 +67,52 @@ object StringUtils extends Logging {
     "(?s)" + out.result() // (?s) enables dotall mode, causing "." to match new lines
   }
 
+  /**
+   * Validate and convert SQL 'similar to' pattern to a Java regular expression.
+   *
+   * This function is similar to escapeLikeRegex, but there are some differences as follows:
+   * 1. If the escape character precedes the meta character for SIMILAR TO, the meta character
+   *    should convert to quote literal.
+   * 2. If '\' is not escape character, need convert to quote literal.
+   * 3. '.', '^' and '$' is not a meta character for SIMILAR TO,
+   *    so we need convert it to quote literal.
+   * 4. Avoid convert the characters of Java regular expression to quote literal.
+   * @param pattern the SQL pattern to convert
+   * @param escapeChar the escape character.
+   * @return the equivalent Java regular expression of the pattern for SIMILAR TO
+   */
+  def escapeSimilarRegex(pattern: String, escapeChar: Char): String = {

Review comment:
       `escapeLikeRegex` produces `the_regex`
   `escapeSimilarRegex` produces `^the_regex$`
   The code is very difference.




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