Hi,

Do you really need to store those dates?  Why not just index them and not store 
them if index size is a concern?

Otis 

--
Sematext -- http://sematext.com/ -- Lucene - Solr - Nutch

----- Original Message ----
From: vivek sar <[EMAIL PROTECTED]>
To: java-user@lucene.apache.org
Sent: Saturday, January 19, 2008 8:06:25 PM
Subject: Using RangeFilter

Hi,

 I have a requirement to filter out documents by date range. I'm using
RangeFilter (in combination to FilteredQuery) to do this. I was under
the impression the filtering is done on documents, thus I'm just
storing the date values, but not indexing them. As every new document
would have a new date value indexing each date value field for every
new document would be very expensive. We index pretty much over 10K
new documents every minute, so I want to minimize the number of values
I need to index.

This is what I want to do,

  doc.add(new Field("optime", getDateStr(rs.getDate("optime")),
                    Field.Store.YES, Field.Index.NO));

 When I do this I always get 0 hits, but if I turn on indexing for
date (Field.Index.NO_NORM) then I'm getting the right result. But,
turning indexing on date field doubles my index size.

 My date format: 20080200000000 (yyyyMMddhhmiss)

Is there any way I can filter on date value without indexing them?

Thanks,
-vivek

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to