Using SIMILARITY
Closed this issue · 4 comments
Hi there, is there any way to take advantage of Postgres' SIMILARITY
keyword to help make a fuzzy search?
I already have installed the extension and am not sure if there is an official way to make use of this with search_cop?
Thanks!
hi, i don't know about this so i doubt we support this, but maybe you have a link to share about the feature?
Hi, thanks for replying!
Sorry I should have specified that this is a function provided by the pg_trgm
extension
https://www.postgresql.org/docs/current/pgtrgm.html
It allows you to do something like
Product.where("similarity(name, ?) > 0.3", table") # Returns products with name including "table"
I can use it directly but seeing as I am already using search_cop for non fuzzy searches in my app I wasn't sure If there was an option somewhere to make use of it.
Thanks
Thanks for the info, but as already assumed search_cop does not support it atm.
OK many thanks for your reply!