You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "Max Gekk (Jira)" <ji...@apache.org> on 2023/10/06 19:35:00 UTC

[jira] [Resolved] (SPARK-45262) Improve the description for `LIKE`

     [ https://issues.apache.org/jira/browse/SPARK-45262?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Max Gekk resolved SPARK-45262.
------------------------------
    Fix Version/s: 4.0.0
       Resolution: Fixed

Issue resolved by pull request 43037
[https://github.com/apache/spark/pull/43037]

> Improve the description for `LIKE`
> ----------------------------------
>
>                 Key: SPARK-45262
>                 URL: https://issues.apache.org/jira/browse/SPARK-45262
>             Project: Spark
>          Issue Type: Documentation
>          Components: SQL
>    Affects Versions: 4.0.0
>            Reporter: Max Gekk
>            Assignee: Max Gekk
>            Priority: Major
>              Labels: pull-request-available
>             Fix For: 4.0.0
>
>
> The description of `LIKE` says:
> {code}
> ... in order to match "\abc", the pattern should be "\\abc"
> {code}
> but in Spark SQL shell:
> {code:sql}
> spark-sql (default)> SELECT c FROM t;
> \abc
> spark-sql (default)> SELECT c LIKE "\\abc" FROM t;
> [INVALID_FORMAT.ESC_IN_THE_MIDDLE] The format is invalid: '\\abc'. The escape character is not allowed to precede 'a'.
> spark-sql (default)> SELECT c LIKE "\\\\abc" FROM t;
> true
> {code}



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

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