Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Gandiva] Wrong filtering using LIKE operator #20618

Closed
asfimport opened this issue Dec 13, 2018 · 2 comments
Closed

[Gandiva] Wrong filtering using LIKE operator #20618

asfimport opened this issue Dec 13, 2018 · 2 comments

Comments

@asfimport
Copy link

asfimport commented Dec 13, 2018

[This issue was discovered during internal testing in Dremio in the java layer]

I noticed that the LIKE operator is not behaving as it should per SQL standard. Notably it seems to consider `.` as a wildcard in some occasions:

SELECT A FROM (VALUES('abcde'), ('abc.e'), ('abcd'), ('abc.'), ('abc')) TBL(A) WHERE A LIKE 'abc_%'
abcde
abc.e
abcd
abc.
abc 
SELECT A FROM (VALUES('abcde'), ('abc.e'), ('abcd'), ('abc.'), ('abc')) TBL(A) WHERE A LIKE 'abc.%'
abcde
abc.e
abcd
abc.
abc 
SELECT A FROM (VALUES('abcde'), ('abc.e'), ('abcd'), ('abc.'), ('abc')) TBL(A) WHERE A LIKE 'abc_'
(no result)
SELECT A FROM (VALUES('abcde'), ('abc.e'), ('abcd'), ('abc.'), ('abc')) TBL(A) WHERE A LIKE 'abc.'
(no result)

 

Based on code review it seemed that same issue may be present in Gandiva. This bug is to verify & fix it in Gandiva as well.

Reporter: Siddharth Dave / @siddharthdave
Assignee: Siddharth Dave / @siddharthdave

Related issues:

Note: This issue was originally created as ARROW-4016. Please see the migration documentation for further details.

@asfimport
Copy link
Author

Praveen Kumar / @praveenbingo:
Was fixed a while back.

@asfimport
Copy link
Author

Todd Farmer / @toddfarmer:
Transitioning issue from Resolved to Closed to based on resolution field value.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant