full text search - Ruby on Rails thinking-sphinx has many through indexing -


cheers! have tour model these associations:

  has_many :tour_in_the_countries   has_many :country, :through => :tour_in_the_countries 

and in tour_index.rb

thinkingsphinx::index.define :tour, :with => :active_record   indexes :title   indexes :preview end 

how add index country's name in case?

this should trick:

indexes tour_in_the_countries.country.name, :as => :countries 

Comments

Popular posts from this blog

monitor web browser programmatically in Android? -

Shrink a YouTube video to responsive width -

wpf - PdfWriter.GetInstance throws System.NullReferenceException -