Solr Results boosted according to keyword match | Community
Skip to main content
Level 2
September 16, 2022
Question

Solr Results boosted according to keyword match

  • September 16, 2022
  • 1 reply
  • 611 views

Does anyone worked on the solr search to boost the result based on maximum search keyword match? Actually I am doing query on Solr to get the result based on multiple keywords search and need to boost the result based on maximum matches keyword. Let say my search term is field:("suresh" or "ramesh" or "vikas"). Now if any result match all three word then should come first. If any any result match only two word then come 2nd position and so on. Thanks !

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.

1 reply

rawvarun
Community Advisor
Community Advisor
June 28, 2023

You can use Phrase Slop in the dismax query parser, it scores documents with query terms in proximity higher than others.