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

Will filter is not supporting starts_with, ends_with with multiple values #65

Open
irfan-shaik opened this issue Mar 14, 2017 · 1 comment

Comments

@irfan-shaik
Copy link

irfan-shaik commented Mar 14, 2017

Ex: SELECT * from fiberbox where field REGEXP '1740|1938|1940';

the operators starts_with and ends_with are firing queries as:
SELECT * from fiberbox where field LIKE '%23,44';
But mysql LIKE won't work for multiple values. REGEX should be used instead of LIKE. Ideal query should be:
SELECT * from fiberbox where field REGEXP '1740|1938|1940';

@irfan-shaik
Copy link
Author

This can be fixed by fixing the Lines- 47-51 in the will_filter/lib/will_filter/containers/text.rb

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

No branches or pull requests

1 participant