lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Paolo Capriotti <>
Subject Using stored fields for scoring
Date Fri, 09 May 2008 14:07:47 GMT
Hi all,
I am looking for a way to include a stored (non-indexed) field in the 
computation of scores for a query.
I have tried using a ValueSourceQuery with a ValueSource subclass that 
simply retrieves the document and gets the field, like:

public float floatVal(int doc) {
   reader.document(doc, selector).getBinaryValue("myfield");

but that's too slow, because it ends up doing a lookup for each matching 
Is it possible to use a stored field in a FunctionQuery or 
ValueSourceQuery in an efficient way (i.e. not dependent on the number 
of retrieved documents)?
If the answer is yes, is it possible to update such a value in place 
without removing and reindexing the document?

Thanks in advance.

Paolo Capriotti

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

View raw message