lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Andreas Sewe <>
Subject Lucene 4.x -> 5.x: Converting FieldValueFilter to FieldValueQuery
Date Wed, 14 Oct 2015 10:06:16 GMT

I am currently in the process of moving from Lucene 4.x to 5.x. As far
as I understand things, a filter like

  filter = new FieldValueFilter("name", false);

translates to

  BooleanQuery filter = new BooleanQuery();
  filter.add(new FieldValueQuery("name"), Occur.FILTER);

with the additional caveat that the field "name" now also needs to be
indexed as SortedDocValuesField, as otherwise the FieldValueQuery won't
work. Am I correct? What are the implications of this change, both in
term of search performance and index size (as I am adding more "fields")?

Best wishes,


Codetrails GmbH
The knowledge transfer company

Robert-Bosch-Str. 7, 64293 Darmstadt
Phone: +49-6151-276-7092
Mobile: +49-170-811-3791

Managing Director: Dr. Marcel Bruch
Handelsregister: Darmstadt HRB 91940

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

View raw message