lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Uroš Jurglič <>
Subject DateFilter and NullPointerException
Date Mon, 17 Dec 2001 16:42:24 GMT
I'm having a problem when using Query and DateFilter for a search. If I
create DateFilter with DateFilter.After with current time&date as parameter,
then I get NullPointerException when executing search
(, DateFilter)). Had anyone experienced something like
that? If I set time just a bit in past, it returns empty hits which is how
it should behave all the time.

code snipet:
	// I have java files as documents, consisting of content
(Field.Text()) and modified (Field.Keyword())
	Query q = new WildcardQuery(new Term("content", "packag*"));
	DateFilter df = DateFilter.After("modified",
	Searcher searcher = new IndexSearcher(path);
	Hits hits =, df);	// line 66

Exception in thread "main" java.lang.NullPointerException
        at Source)
        at Source)
        at Source)
        at<init>(Unknown Source)
        at Source)
        at Search.main(


  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message