Re: omitTermFreqAndPositions in a TextField fieldType

2011-06-17 Thread Ahmet Arslan
> Does it even make sense to use omitTermFreqAndPositions for
> a TextField, or am I perhaps doing something I shouldn't
> be?

Yes it makes sense to disable tf, positions and norms if you don't need them. 
For example, I have this category_name field where its definition includes:

omitNorms="true" omitTermFreqAndPositions="true"

I don't need PhraseQuery, lenght normalization, index time boost, etc.
I only display three (rows=3) category names for a given query.


omitTermFreqAndPositions in a TextField fieldType

2011-06-16 Thread Michael Ryan
Is it possible to use omitTermFreqAndPositions="true" in a  
declaration that uses class="solr.TextField"? I've tried doing this and it does 
not seem to work (i.e., the prx file size does not change). Using it in a 
 declaration does work, but I'd rather set it in the  so I 
don't have to repeat it multiple times in my schema.

>From my schema.xml file:

  


  


In the TextField class I found that it disables OMIT_TF_POSITIONS, which I'm 
assuming is the cause of my problem:
if (schema.getVersion()> 1.1f) properties &= ~OMIT_TF_POSITIONS;

Does it even make sense to use omitTermFreqAndPositions for a TextField, or am 
I perhaps doing something I shouldn't be?

-Michael