[英]Limit domaing before full text search using pg_search in ruby on rails
Is there to specify a limited table domain for being searched using pg_search ? 是否指定使用pg_search进行搜索的有限表域?
I'm thinking about using a number of chained calls to where
on the ActiveRecord model before issuing a pg_search
scoped search. 我正在考虑在发出pg_search
范围搜索之前对ActiveRecord模型上的where
使用多个链式调用。
The latest version has the ability to operate on the results returned by where
or order
etc. 最新版本能够根据where
或order
等返回的结果进行操作。
So you can perform a search such as: 所以你可以执行搜索,例如:
YourModel.where(id: "some condition").search("query")
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.