lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From emmanuel Gosse <>
Subject How could i take into account the other part of a field which not matches with the query
Date Sun, 14 Oct 2012 11:51:21 GMT
> Hi,

> How could i take into account in a query the fact that the searched words
> could be more precise in a document field than an other.

example :
2 documents :
doc1 :  title : taxi
doc2 : title : taxi driver

Query : TermQuery : title:taxi

How could doc1 has a better score than doc2 ?

That's a very basic example.

By rewriting a query, i have not enough lucene skills.
The way I think is more to use an other field with length or number of
words in title to use in a sort. (i don't use tf or idf in similarity).

> Best Regards
> E

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message