On 08.08.2012 20:56, Bing Hua wrote:
Not quite understand but I'd explain the problem I had. The response would
contain only fields and a list of field values that match the query.
Essentially it's querying for field values rather than documents. The
underlying use case would be, when typing in a quick search box, the drill
down menu may contain matches on authors, on doctitles, and potentially on
other fields.

Still thanks for your response and hopefully I'm making it clearer.
Bing

Hi Bing,

hmh, I implemented myself an autosuggest component that does exactly this. You could specify which field you wanted to query, give an optional weight to them, and the component returned a list of all fields and values beginning with the queried string. Either combined or per field, depending on your configuration.

However, that was with Solr 1.4.0, when there was no genuine suggest component available. Since then, the Suggester component has been implemented: http://wiki.apache.org/solr/Suggester/

This relies on the spell check dictionary and works better than a simple term dictionary approach. And that's the reason why I didn't bother my old code any more.

So maybe you're simply looking for the suggester component? If not, I can try to make my old-style component work with a current Solr version and spread it around. Just tell me.

Greetings,
Kuli

Reply via email to