I agree with David, I see a Ton of wrong configuration in yours …
Please have a read of the documentation linked .
And take a look to this mailing list, we have tons of messages related that
can help you.
A first suggestion for you anyway, is to take care of your analysis.
The suggestions will be the tokens you produce with the analyser you
provide to the Suggester, so make extra care of them.
I see this :

 <str name="field">text</str>
      <str name="suggestAnalyzerFieldType">string</str>

Which does not make a lot of sense …

Cheers

2015-06-26 7:35 GMT+01:00 ssharma7...@gmail.com <ssharma7...@gmail.com>:

> Hi,
> I am new to Solr & have installed Solr 5.1. I am trying to get the
> Suggester
> component working without any success, the following are the relevant
> details:
>
> *Schema.xml*
> <field name="text" type="c_text" indexed="true" stored="true"
> termVectors="true" termPositions="true" termOffsets="true" />
>
>                 <fieldType name="c_text" class="solr.TextField"
> positionIncrementGap="100">
>                         <analyzer type="index">
>                                 <tokenizer
> class="solr.UAX29URLEmailTokenizerFactory"/>
>                                 <filter class="solr.StopFilterFactory"
> ignoreCase="true"
> words="lang/stopwords_en.txt" />
>                                 <filter
> class="solr.ASCIIFoldingFilterFactory"/>
>                                 <filter
> class="solr.EnglishPossessiveFilterFactory"/>
>                                 <filter
> class="solr.RemoveDuplicatesTokenFilterFactory"/>
>                                 <filter class="solr.TrimFilterFactory"/>
>                                 <filter
> class="solr.LowerCaseFilterFactory"/>
>                         </analyzer>
>                         <analyzer type="query">
>                                 <tokenizer
> class="solr.UAX29URLEmailTokenizerFactory"/>
>                                 <filter class="solr.StopFilterFactory"
> ignoreCase="true"
> words="lang/stopwords_en.txt" />
>                                 <filter
> class="solr.ASCIIFoldingFilterFactory"/>
>                                 <filter
> class="solr.EnglishPossessiveFilterFactory"/>
>                                 <filter
> class="solr.LowerCaseFilterFactory"/>
>                         </analyzer>
>                 </fieldType>
>
> *solr-config.xml*
>
> <searchComponent name="suggest" class="solr.SuggestComponent">
>    <lst name="suggester">
>       <str name="name">textSuggester</str>
>       <str name="lookupImpl">FuzzyLookupFactory</str>
>       <str name="dictionaryImpl">DocumentDictionaryFactory</str>
>       <str name="field">text</str>
>       <str name="suggestAnalyzerFieldType">string</str>
>       <str name="buildOnCommit">true</str>
>    </lst>
> </searchComponent>
>
>   <requestHandler name="/suggest" class="solr.SearchHandler"
>                   startup="lazy" >
>     <lst name="defaults">
>       <str name="suggest">true</str>
>       <str name="suggest.count">10</str>
>       <str name="suggest.dictionary">textSuggester</str>
>     </lst>
>     <arr name="components">
>       <str>suggest</str>
>     </arr>
>   </requestHandler>
>
> *Query to get suggestions*
>
> http://localhost:8983/solr/portal_documents/suggest?suggest=true&suggest.dictionary=textSuggester&suggest.q=testing
>
> *Above Query Output*
> <response>
> <lst name="responseHeader">
> <int name="status">0</int>
> <int name="QTime">31</int>
> </lst>
> <lst name="suggest">
> <lst name="textSuggester">
> <lst name="testing">
> <int name="numFound">0</int>
> <arr name="suggestions"/>
> </lst>
> </lst>
> </lst>
> </response>
>
> The data is getting indexed properly, as can be seen from image below:
> <http://lucene.472066.n3.nabble.com/file/n4214086/solr-suggester.jpg>
>
> Regards,
> Sachin Vyas.
>
>
>
>
> --
> View this message in context:
> http://lucene.472066.n3.nabble.com/Solr-Suggester-not-working-tp4214086.html
> Sent from the Solr - User mailing list archive at Nabble.com.
>



-- 
--------------------------

Benedetti Alessandro
Visiting card : http://about.me/alessandro_benedetti

"Tyger, tyger burning bright
In the forests of the night,
What immortal hand or eye
Could frame thy fearful symmetry?"

William Blake - Songs of Experience -1794 England

Reply via email to