lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Senthil Kumar K" <>
Subject RE: How to search document for modified date
Date Sun, 21 Sep 2003 09:38:46 GMT

  Erik thanks for your reply. 
  How to do using QueryParser expressions.


-----Original Message-----
From: Erik Hatcher []
Sent: Saturday, September 20, 2003 6:42 PM
To: Lucene Users List
Subject: Re: How to search document for modified date

On Saturday, September 20, 2003, at 07:38  AM, Senthil Kumar K wrote:
> Hi,
>     How to make query to search in the lucene index
> for document with specified date.While indexing
> i made
>  doc.add(Field.Keyword("modified",
> DateField.timeToString(f.lastModified())))
> like this.
> If any one knows how to search for documents with specific date.
> please give me a sample query.

Query query = new TermQuery(new Term("modified", 

You could also do this with QueryParser expressions, although there are 
some caveats to date fields and its usage (must use default locale 
short date format strings, for instance).


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message