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

ilike operator breaks with numeric column #918

Open
natoszme opened this issue May 6, 2024 · 2 comments
Open

ilike operator breaks with numeric column #918

natoszme opened this issue May 6, 2024 · 2 comments
Labels
bug Something isn't working will accept PR

Comments

@natoszme
Copy link

natoszme commented May 6, 2024

Hi there!

First of all, thank you for such a great library!

I started to use it a couple of days ago and I'd like to know whether it's possible to add operators to the search param.

My use case is as follows: I want to be able to search by a string with several words, and since search doesn't support $in operator, it's doing the default like with %{string}% comparison but with the full string (with spaces). Each word is a sub-string I want to search in a different column (that's why supporting $in operator in search would be a possible solution).

I tried manually doing the filter in the client, specifying each searchableColumn as a separate filter query param, but the numeric columns break (I want my search input to support id's, which works great with the search feature) .

Maybe there is a different approach to this problem using already existing features?

Thanks!

@ppetzold
Copy link
Owner

.Oh I see - would consider this a bug of the $ilike operator then. should add string/text cast.

happy to accept PR :)

@ppetzold ppetzold changed the title Search operators ilike operator breaks with numeric column May 17, 2024
@ppetzold ppetzold added bug Something isn't working will accept PR labels May 17, 2024
@bountyhub-bot
Copy link

🚀 Bounty Alert!

💰 A bounty of $10.00 has been created by omarsoufiane on BountyHub.

🔗 Claim this bounty by submitting a pull request that solves the issue!

Good luck, and happy coding! 💻

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working will accept PR
Projects
None yet
Development

No branches or pull requests

3 participants