lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Markus Jelsma <markus.jel...@buyways.nl>
Subject RE: Phrase search
Date Mon, 02 Aug 2010 18:27:11 GMT
Well, the WordDelimiterFilterFactory in your query analyzer clearly makes "Apple 2" out of
"Apple2", that's what it's for. If you're looking for an exact match, use a string field.
Check the output with the debugQuery=true parameter.

 

Cheers, 
 
-----Original message-----
From: johnmunir@aol.com
Sent: Mon 02-08-2010 20:18
To: solr-user@lucene.apache.org; 
Subject: Phrase search


Hi All,

I don't understand why i'm getting this behavior.  I was under the impression if I search
for "Apple 2" (with quotes and space before 2 ) it will give me different results vs. if I
search for "Apple2" (with quotes and no space before 2 ), but I'm not!  Why? 

Here is my fieldType setting from my schema.xml:

   <fieldType name="text" class="solr.TextField" positionIncrementGap="100">
     <analyzer type="index">
       <tokenizer class="solr.WhitespaceTokenizerFactory"/>
       <!-- in this example, we will only use synonyms at query time
       <filter class="solr.SynonymFilterFactory" synonyms="index_synonyms.txt" ignoreCase="true"
expand="false"/>
       -->
       <filter class="solr.StopFilterFactory" ignoreCase="true" words="stopwords.txt"/>
       <filter class="solr.WordDelimiterFilterFactory" generateWordParts="0" generateNumberParts="1"
catenateWords="1" catenateNumbers="1" catenateAll="0"/>
       <filter class="solr.LowerCaseFilterFactory"/>
       <filter class="solr.EnglishPorterFilterFactory" protected="protwords.txt"/>
       <filter class="solr.RemoveDuplicatesTokenFilterFactory"/>
     </analyzer>
     <analyzer type="query">
       <tokenizer class="solr.WhitespaceTokenizerFactory"/>
       <!-- <filter class="solr.SynonymFilterFactory" synonyms="synonyms.txt" ignoreCase="true"
expand="true"/> -->
       <filter class="solr.StopFilterFactory" ignoreCase="true" words="stopwords.txt"/>
       <filter class="solr.WordDelimiterFilterFactory" generateWordParts="0" generateNumberParts="1"
catenateWords="1" catenateNumbers="1" catenateAll="0"/>
       <filter class="solr.LowerCaseFilterFactory"/>
       <filter class="solr.EnglishPorterFilterFactory" protected="protwords.txt"/>
       <filter class="solr.RemoveDuplicatesTokenFilterFactory"/>
     </analyzer>
   </fieldType>

What I am missing?!!  What part of my solr.WordDelimiterFilterFactory need to change (if
that s where the issue is)?

I m using Solr 1.2

Thanks in advanced.

-M


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message