If I search for a piece of a word other than the first few characters of the word it does not find. Type if I search for "Car" it searches correctly, but now if I search for "los" or "arlos" it returns empty.
I have in the Client table:
id name
1 Carlos da Silva
2 Tiago Casanova
3 Pedro Gomes
In my model:
searchable do
text :name
end
No controller:
@clients = Client.search do
fulltext params[:search]
paginate :page => params[:page] || 1
end
In my schema.xml
<fieldType name="text" class="solr.TextField" omitNorms="false">
<analyzer type="index">
<tokenizer class="solr.StandardTokenizerFactory"/>
<filter class="solr.StandardFilterFactory"/>
<filter class="solr.LowerCaseFilterFactory"/>
<filter class="solr.EdgeNGramFilterFactory" minGramSize="1" maxGramSize="15" />
<filter class="solr.PorterStemFilterFactory" />
</analyzer>
<analyzer type="query">
<tokenizer class="solr.StandardTokenizerFactory"/>
<filter class="solr.StandardFilterFactory"/>
<filter class="solr.LowerCaseFilterFactory"/>
<filter class="solr.ASCIIFoldingFilterFactory" />
</analyzer>
</fieldType>