scoped_search
scoped_search copied to clipboard
Optional sanitizing of _ and % in search values
Hey everyone, we are trying to implement search on strings containing a lot of underscore characters and would like to have an optional sanitizing of the right side of search values. We could theoretically do that in our controllers, but that would require and additional run of your parser in order to only parse the value and not the whole search string. Would it be possible to implement this on your side in an opt-in manner? Thank you.
https://api.rubyonrails.org/classes/ActiveRecord/Sanitization/ClassMethods.html#method-i-sanitize_sql_like