lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nithyavembu <>
Subject Re: How to search multiphrase or a middle term in a word???
Date Wed, 05 Mar 2008 13:38:07 GMT

Thanks Hoss.

 As you said i tried NGrimTokenizer, but still i didnt get the result.
 I just added 
       <tokenizer class="solr.NGramTokenizerFactory" minGram="1"
 in schema.xml during indexing and querying. But it didnt work.

 But after added this tokenizer this scenario also didnt work
  Index data : sweetheart,sweetHeart.
  Search data : Heart or heart
  Result : sweetHeart

  As i explored i didnt correctly understood the behaviour of NGrim
  I want to know the usage and the configuration in code using NGrim
  Please help me out.

your "master" examples work part of the time because of the 
WordDelimiterField can tell at indextime that the capital M in the middle 
of the word is a good place to split on.

without hints like that at index time, the only way to do "middle of the 
word" searches is with wildcard type queries -- which ar really 

You might want to read a it about N-Grams and consider using an 
NGramTokenizer to chunk up your input words into ngrams for easy searching 
on pieces of words.


View this message in context:
Sent from the Solr - User mailing list archive at

View raw message