Mailing List Archive

Using a DateFilter without a query
Hi,

is it possible to use a DateFilter without a query. I would like to get all
Documents from within a certain period of time WITHOUT specifying any query
except the range of dates.

OR

Is there something like query that will always return all documents from an
index?

Jan


--
To unsubscribe, e-mail: <mailto:lucene-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:lucene-user-help@jakarta.apache.org>
Re: Using a DateFilter without a query [ In reply to ]
Hello,

--- Jan_Stövesand <j.stoevesand@finix.de> wrote:
> Hi,
>
> is it possible to use a DateFilter without a query. I would like to
> get all
> Documents from within a certain period of time WITHOUT specifying any
> query except the range of dates.

I don't know, but I'd like to know. Have you tried it?

> Is there something like query that will always return all documents
> from an index?

This has been asked in the past. It can't be done, but you could work
around it by adding a field with a known, constant value to each
document. Then searching for that will give you all documents in the
index.
Is there a better way?

Otis


__________________________________________________
Do You Yahoo!?
Check out Yahoo! Shopping and Yahoo! Auctions for all of
your unique holiday gifts! Buy at http://shopping.yahoo.com
or bid at http://auctions.yahoo.com

--
To unsubscribe, e-mail: <mailto:lucene-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:lucene-user-help@jakarta.apache.org>
RE: Using a DateFilter without a query [ In reply to ]
Useful alternative to DateFilter is using RangeQuery, containing string
representations of date objects (DateField.dateToString())
for lower and upper term. At least one of terms must be not null, in case
you want to search after or before specified date. It seems to work better
than filtering with DateFilter - I get no null pointer ex.

Uros.


-----Izvorno sporocilo-----
Od: Jan Stövesand [mailto:j.stoevesand@finix.de]
Poslano: 17. december 2001 17:57
Za: Lucene Users List
Zadeva: Using a DateFilter without a query


Hi,

is it possible to use a DateFilter without a query. I would like to get all
Documents from within a certain period of time WITHOUT specifying any query
except the range of dates.

OR

Is there something like query that will always return all documents from an
index?

Jan


--
To unsubscribe, e-mail:
<mailto:lucene-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail:
<mailto:lucene-user-help@jakarta.apache.org>
RE: Using a DateFilter without a query [ In reply to ]
> From: jurglic@parsek.net [mailto:jurglic@parsek.net]
>
> Useful alternative to DateFilter is using RangeQuery,
> containing string
> representations of date objects (DateField.dateToString())
> for lower and upper term.

Probably we should create a subclass of RangeQuery called DateQuery that
makes this very simple.

Doug

--
To unsubscribe, e-mail: <mailto:lucene-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:lucene-user-help@jakarta.apache.org>