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

Balazs Hevele resolved IMPALA-14731.
------------------------------------
    Fix Version/s: Impala 5.0.0
       Resolution: Fixed

> LIKE starting with % and ending with escaped % does not work correctly
> ----------------------------------------------------------------------
>
>                 Key: IMPALA-14731
>                 URL: https://issues.apache.org/jira/browse/IMPALA-14731
>             Project: IMPALA
>          Issue Type: Bug
>            Reporter: Balazs Hevele
>            Assignee: Balazs Hevele
>            Priority: Critical
>              Labels: Correctness
>             Fix For: Impala 5.0.0
>
>
> As an example, {noformat}LIKE "%abc\%"{noformat} matches for any string 
> containing "abc\", instead of "abc%" with any prefix.
> A very similar bug was fixed in 
> https://issues.apache.org/jira/browse/IMPALA-2422 which fixes similar cases 
> without the % at the start, e.g. {noformat}LIKE "abc\%"{noformat}.
> Example queries:
> 1.
> {noformat}
> +----------------------+
> | 'abc%' like '%abc\%' |
> +----------------------+
> | false                | (should be true)
> +----------------------+
> {noformat}
> 2.
> {noformat}
> +-----------------------+
> | 'abc\\' like '%abc\%' |
> +-----------------------+
> | true                  | (should be false)
> +-----------------------+
> {noformat}



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

Reply via email to