Hello. We've just upgraded to 4.3.1 from 2.9.2 and are having a problem with native ordering of search results.

We always want documents returned in order of "rank", which for us is a float value that we assign to each document at index time. Rank depends in whether, for example, the item is in stock and how recent it is. We also store the rank as a field in the index. We don't use Lucene's scoring system for ordering results at all.

In 2.9.2, we used to set the boost on the document (we encoded our rank to ensure nice distribution over float range that is ultimately encoded as a 1 byte norm), and all results were returned in rank order without using a sort.

In 4.3.1, the document level boost is gone and only fields can be boosted. Some queries, like a MatchAllDocsQuery, don't seem to take field level boosts into account at all when ordering results.

Is there an easy way in Lucene 4 to set the natural order for results in the absence of an explicit sort?

Thanks!

---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscr...@lucene.apache.org
For additional commands, e-mail: java-user-h...@lucene.apache.org

Reply via email to