Thanks a lot, but the precisionStep is still very vague to me! Could you give 
me a example? 

-----Original Message-----
From: Li Li [mailto:fancye...@gmail.com] 
Sent: 2012年6月28日 11:25
To: solr-user@lucene.apache.org
Subject: Re: what is precisionStep and positionIncrementGap

1. precisionStep is used for ranging query of Numeric Fields. see 
http://lucene.apache.org/core/old_versioned_docs/versions/3_5_0/api/all/org/apache/lucene/search/NumericRangeQuery.html
2. positionIncrementGap is used for phrase query of multi-value fields e.g. 
doc1 has two titles.
   title1: ab cd
   title2: xy zz
   if your positionIncrementGap is 0, then the position of the 4 terms are 
0,1,2,3.
   if you search phrase "cd xy", it will hit. But you may think it should not 
match
   so you can adjust positionIncrementGap to a larger one. e.g. 100.
   Then the positions now are 0,1,100,101. the phrase query will not match it.

On Thu, Jun 28, 2012 at 10:00 AM, ZHANG Liang F 
<liang.f.zh...@alcatel-sbell.com.cn> wrote:
> Hi,
> in the schema.xml, usually there will be fieldType definition like 
> this: <fieldType name="int" class="solr.TrieIntField" 
> precisionStep="0" omitNorms="true" positionIncrementGap="0"/>
>
> the precisionStep and positionIncrementGap is not very clear to me. Could you 
> please elaborate more on these 2?
>
> Thanks!
>
> Liang

Reply via email to