Have a look at the FunctionQuery stuff:
http://wiki.apache.org/solr/FunctionQuery
On Nov 20, 2008, at 4:42 PM, Lance Norskog wrote:
Is it possible to boost a document by the contents of a field? Given
the
query:
text field:value
I want to return all documents with 'text'. Documents where 'field =
value'
boosted over documents where 'field = some other value'.
This query does it:
(text field:value)^100 (text -field:value)
Is there a simpler way? (I might have left out crucial AND/OR
clauses, but
you get the picture.)
I don't remember much on this topic. Does it appear in the Lucene
lists? Is
there a Lucene feature or open issue?
Thanks,
Lance
--------------------------
Grant Ingersoll
Lucene Helpful Hints:
http://wiki.apache.org/lucene-java/BasicsOfPerformance
http://wiki.apache.org/lucene-java/LuceneFAQ