The simple rule is that a wildcard suppresses any analysis steps that are
not "multi-term aware". Unfortunately, the word delimiter filter is not
"multi-term aware" (the lower case filter is). So, the query tries to find
"abc.def@gmail" as a single (wildcard) term, which it won't find, since the
index-time analysis will have indexed that same text as the three terms "abc
def gmail".
Your query with double quotes works because the asterisk is treated as a
simple punctuation character that the word delimiter filter ignores, so your
query is equivalent to "abc def gmail", exactly as those terms were indexed.
-- Jack Krupansky
-----Original Message-----
From: adfel70
Sent: Monday, March 11, 2013 5:36 AM
To: solr-user@lucene.apache.org
Subject: "abc.def@gmail*" not retrieved but without double quotes retrieved
I have the following field type:
<fieldtype name="email_type" class="solr.TextField">
<analyzer>
<tokenizer class="solr.StandardTokenizerFactory"/>
<filter class="solr.LowerCaseFilterFactory"/>
<filter class="solr.WordDelimiterFilterFactory"
generateWordParts="1" generateNumberParts="1" catenateWords="0"
catenateNumbers="0" catenateAll="0" splitOnCaseChange="0"/>
</analyzer>
</fieldtype>
the following field:
<field name="email" type="email_type" indexed="true" stored="true"/>
I add the value "abc....@gmail.com" to this email field.
When I search :
1. "abc.def@gmail*" - I get the result.
2. abc.def@gmail* (without doeble quotes) - I dont get the result.
Am I missing something regarding wildcards and exact phrase searches?
thanks.
--
View this message in context:
http://lucene.472066.n3.nabble.com/abc-def-gmail-not-retrieved-but-without-double-quotes-retrieved-tp4046268.html
Sent from the Solr - User mailing list archive at Nabble.com.