Rails 3 + Thinking Sphinx: How to put field weight on Application Wide Search? -


i have collection model , book model. collection has name column, while book has title column. notice collection has name, , book has title.

i'm looking through this: http://pat.github.io/thinking-sphinx/searching.html#fieldweights field weights on 1 specific model. need field weights when application wide search in both collection , book using thinkingsphinx.search("search term").

am allowed put field weights columns don't exist in both tables? want field_weights: {name: 100, title: 1}. when try add second argument thinkingsphinx.search('toy', field_weights: {name: 100, title: 1}) still doesn't put collection first. result classes still ["book", "collection", "book", "book", "book"]

perhaps purpose of :ranker?


Comments

Popular posts from this blog

javascript - jquery or ashx not working -

opencv - DataType<cv::detail::deriv_type>::depth what is it used for -

python 3.x - Mapping specific letters onto a list of words -