I want to show more matches for names using soundex. However, soundex sometimes gives awful results so what I'd like to do is concatenate two sets of results. The first set with morphology set to 'none'. The second half with soundex.
I running thinking-sphinx 1.3.18.
Here is the model:
class LdapEntity < ActiveRecord::Base
define_index 'ldap_entity_morphology_none' do
# indexes...
# set_property...
# has...
end
define_index 'ldap_entity_morphology_soundex' do
# indexes...
# set_property...
set_property :morphology => 'soundex'
# has...
end
# some stuff
end
Currently, I only get results for the index with soundex. What should
change so both indexes are shown with soundex results at the end?
Here is the controller:
@search = {
:everything => {
:sections => [:pages,:people,:news,:events],
:classes => [Page, ExternalPage, NewsItem, Event, LdapEntity],
:without => { :page_is_broken => true, :hide_from_search => true },
},
:people => {
:sections => [:people],
:classes => [LdapEntity],
},
:pages => {
:sections => [:pages],
:classes => [Page, ExternalPage],
:without => { :page_is_broken => true, :hide_from_search=> true },
},
:news => {
:sections => [:news],
:classes => [NewsItem],
},
:events => {
:sections => [:events],
:classes => [Event],
},
}
further down,
results = ThinkingSphinx.send('search',
parsed[section][:searchString],@search[section])
--
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?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
