lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Shalin Shekhar Mangar <shalinman...@gmail.com>
Subject Re: WordDelimiterFilter to QueryParser to MultiPhraseQuery?
Date Thu, 03 Sep 2009 07:23:57 GMT
On Mon, Aug 31, 2009 at 10:47 PM, jOhn <netcam@gmail.com> wrote:

> This is mostly my misunderstanding of catenateAll="1" as I thought it would
> break down with an OR using the full concatenated word.
>
> Thus:
>
> Jokers Wild -> { jokers, wild } OR { jokerswild }
>
> But really it becomes: { jokers, {wild, jokerswild}} which will not match.
>
> And if you have a mistyped camel case like:
>
> jOkerswild -> { j, {okerswild, jokerswild}} again no match.
>
>
Sorry for the late reply. You still haven't given the fieldtype definition
that you were using.

I tried:

<fieldtype name="wdf_preserve_catenate" class="solr.TextField">
      <analyzer>
          <tokenizer class="solr.KeywordTokenizerFactory"/>
          <filter class="solr.WordDelimiterFilterFactory"
generateWordParts="1" generateNumberParts="1" catenateWords="1"
catenateNumbers="1" catenateAll="1" splitOnCaseChange="1"
preserveOriginal="1"/>
          <filter class="solr.LowerCaseFilterFactory"/>
      </analyzer>
    </fieldtype>

And I tried indexing "Jokers Wild" which matches when I query for
"jOkerswild" and "jokerswild". Note that if you change the tokenizer to
WhiteSpaceTokenizer then such queries won't match.

-- 
Regards,
Shalin Shekhar Mangar.

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