Hi Daniel In this case, I'd recommend having the index defined for the localisation model instead - that way, there's single language_id, country, state, etc values for each search record, and you can pull in the parent object's data as well.
Happy to offer a bit more in the way of specifics if you want to talk through your model and localisation setup (plus Thinking Sphinx version). Cheers -- Pat On 08/07/2013, at 8:20 AM, Daniel Vandersluis wrote: > I'm hoping someone might have a good idea for this problem. I want to collect > records that have attributes that are localized (ie. country name, state > name, etc.). The attribute saved in the index is the ID, so when I try to > order by one of those attributes, obviously it'll sort numerically by ID. The > main record that is being indexed is not localized, so having separate > indexes per locale doesn't seem like a solution in this case. > > Without Sphinx I would just join on the locale table for the given model > (each attribute works as a one-to-many -- one state has many localizations) > with the correct language_id, but I'm not sure how this would (or can) > translate to Sphinx. Any thoughts? > > -- > You received this message because you are subscribed to the Google Groups > "Thinking Sphinx" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To post to this group, send email to [email protected]. > Visit this group at http://groups.google.com/group/thinking-sphinx. > For more options, visit https://groups.google.com/groups/opt_out. > > -- You received this message because you are subscribed to the Google Groups "Thinking Sphinx" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/thinking-sphinx. For more options, visit https://groups.google.com/groups/opt_out.
