Lucene: Retrieve ALL entries as search result

Lucene is a very powerfull full text indexing and searching tool. The search query syntax is well documented on the project page.
Unfortunately, you always have to pass a non-empty search query string to lucene, otherweise lucene will throw an exception.

If you want to receive ALL entries as a search result (e.g. user enters nothing into the search field and you want to present an unfiltered list of all elements to him), you can use the following query string:


Short URL for this post:
This entry was posted in Java EE and tagged . Bookmark the permalink.