我有一个包含
... Sie kennen zentrale Stationen des Lebenswegs Muhammads. • Sie ke ...
我已经这样配置了
<fieldType name="text" class="solr.TextField" positionIncrementGap="100">
<analyzer>
<tokenizer class="solr.WhitespaceTokenizerFactory" />
<filter class="solr.WordDelimiterFilterFactory"
generateWordParts="1" generateNumberParts="0" catenateWords="1"
catenateNumbers="1" catenateAll="0" splitOnCaseChange="1"
splitOnNumerics="0" stemEnglishPossessive="0"/>
<filter class="solr.LowerCaseFilterFactory" />
<filter class="solr.ReversedWildcardFilterFactory" />
<filter class="solr.LengthFilterFactory" min="1" max="100" />
</analyzer>
</fieldType>
但
q=volltext:lebenswegs
q=volltext:Lebenswegs
没有结果,为什么?
q=volltext:lebensweg*
找到文档
我正在使用 solr 1.4
编辑:
拆分配置
<fieldType name="text" class="solr.TextField" positionIncrementGap="100">
<analyzer type="index">
<tokenizer class="solr.WhitespaceTokenizerFactory" />
<filter class="solr.WordDelimiterFilterFactory"
generateWordParts="1" generateNumberParts="0" catenateWords="1"
catenateNumbers="1" catenateAll="0" splitOnCaseChange="1"
splitOnNumerics="0" stemEnglishPossessive="0"/>
<filter class="solr.LowerCaseFilterFactory" />
<filter class="solr.ReversedWildcardFilterFactory" />
<filter class="solr.LengthFilterFactory" min="1" max="100" />
</analyzer>
<analyzer type="query">
<tokenizer class="solr.WhitespaceTokenizerFactory" />
<filter class="solr.WordDelimiterFilterFactory"
generateWordParts="1" generateNumberParts="0" catenateWords="1"
catenateNumbers="1" catenateAll="0" splitOnCaseChange="1"
splitOnNumerics="0" stemEnglishPossessive="0"/>
<filter class="solr.LowerCaseFilterFactory" />
<filter class="solr.LengthFilterFactory" min="1" max="100" />
</analyzer>
</fieldType>
导致相同的结果
分析器似乎匹配,但我的查询结果为空
查询调试:
<lst name="debug">
<str name="rawquerystring">volltext:Lebenswegs</str>
<str name="querystring">volltext:Lebenswegs</str>
<str name="parsedquery">volltext:lebenswegs</str>
<str name="parsedquery_toString">volltext:lebenswegs</str>
<lst name="explain"/>
<str name="QParser">LuceneQParser</str>
<lst name="timing">
<double name="time">1.0</double>
<lst name="prepare">
<double name="time">1.0</double>
<lst name="org.apache.solr.handler.component.QueryComponent">
<double name="time">0.0</double>
</lst>
<lst name="org.apache.solr.handler.component.FacetComponent">
<double name="time">0.0</double>
</lst>
<lst name="org.apache.solr.handler.component.MoreLikeThisComponent">
<double name="time">0.0</double>
</lst>
<lst name="org.apache.solr.handler.component.HighlightComponent">
<double name="time">0.0</double>
</lst>
<lst name="org.apache.solr.handler.component.StatsComponent">
<double name="time">0.0</double>
</lst>
<lst name="org.apache.solr.handler.component.DebugComponent">
<double name="time">1.0</double>
</lst>
</lst>
<lst name="process">
<double name="time">0.0</double>
<lst name="org.apache.solr.handler.component.QueryComponent">
<double name="time">0.0</double>
</lst>
<lst name="org.apache.solr.handler.component.FacetComponent">
<double name="time">0.0</double>
</lst>
<lst name="org.apache.solr.handler.component.MoreLikeThisComponent">
<double name="time">0.0</double>
</lst>
<lst name="org.apache.solr.handler.component.HighlightComponent">
<double name="time">0.0</double>
</lst>
<lst name="org.apache.solr.handler.component.StatsComponent">
<double name="time">0.0</double>
</lst>
<lst name="org.apache.solr.handler.component.DebugComponent">
<double name="time">0.0</double>
</lst>
</lst>
</lst>
</lst>