(12/01/16 19:43), stockii wrote:
Why does this not work?
<fieldType name="city" class="solr.TextField">
<analyzer>
<charfilter class="solr.PatternReplaceFilterFactory"
pattern="^(\,
)$" replacement="" replace="first" />
OR
<charfilter class="solr.PatternReplaceFilterFactory"
pattern=", "
replacement="" replace="first" />
<tokenizer class="solr.WhitespaceTokenizerFactory" />
</analyzer>
</fieldType>
i dont know where is my error?
i only want to replace comma with a blank ...
Try to:
1. use <char*F*ilter/> tag instead of <char*f*ilter/>
2. use PatternReplace*Char*FilterFactory instead of PatternReplaceFilterFactory
and you cannot use replace="first or all" with the CharFilter.
PatternReplaceFilter can accept replace because it just processes a token
each time, on the other hand, PatternReplaceCharFilterFactory should process
CharStream.
koji
--
http://www.rondhuit.com/en/