lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Chuck Williams <ch...@allthingslocal.com>
Subject Re: NumberTools
Date Mon, 21 Mar 2005 19:17:08 GMT

>: One annoyance I have run across is the impedance mismatch between
>: range queries and sorting.
>:
>: If your terms are  indexed as standard numbers, then integer sorting
>: is fast, but range queries don't work (for negative values).  If you
>: format the terms such that range queries work for any integer, then
>: you have to use the slower string (or custom) sorting.
>:
>: Is there a way around this besides writing my own custom sorting hit collector?
>  
>
I solve this problem by using two separate fields:  one for range 
queries and one for sorting, each formatted appropriately.  Adds very 
little space to the index.  A bit ugly, but better than writing a custom 
hit collector.

A better solution that unified these formats, perhaps along the lines 
Hoss suggests, would be appreciated.

Chuck



---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org


Mime
View raw message