Hi,

I had a similar problem for categories and locations of companies. The way
I did it was to join everything (categories and locations) on a single
field, join the two values with a predefined separator and query the
spellchecker for the whole sentence. The spellchecker keeps the separator
on the collation suggestion and so I can get both values back with its
suggestions.

Bruno

On Thu, Nov 13, 2014 at 7:39 PM, Carlos Maroto <charlie.mar...@gmail.com>
wrote:

> Hi,
>
>
>
> Has anyone configured two spellchecker components in Solr so that a single
> search returns two different sets of suggestions?
>
>
>
> *Use Case:* Combined index of business names and categories of those
> businesses
>
> *Sample Query:* thisle  (misspelling by the user)
>
> *Expected Results:* Thistle (actual name of a business)
>
> *Current Suggestion:* tiles (“tiles” is a more common term than “thistle”
> in the spellcheck field and therefore considered as a better suggestion by
> the spellchecker)
>
> *Expected Suggestions:*  Since we want to configure one spellchecker to
> work against a field that indexes categories content and another
> spellchecker that indexes business names, then we would expect two
> different suggestions: “tiles” (from the categories spellchecker) and
> “thistle” (from the business names spellchecker)
>
>
>
> I tried:
>
> 1-    1-  Configuring two different spellcheckers and calling both as
> <last-components> in the searchHandler, each spellchecker has a different
> field configured to generate the suggestions
>
> 2- 2-     Configuring two <lst name="spellchecker"> based on different
> fields in the searchComponent configuration for the spellcheck component
>
>
> I can only get suggestions from one of the components
>
>
>
> Any ideas?
>



-- 
<http://about.me/brunorene>
Bruno René Santos
about.me/brunorene
[image: Bruno René Santos on about.me]
  <http://about.me/brunorene>

Reply via email to