0

i'd like to boost documents in solr only if a certain field has a fixed value for example:

i'd like to boost all documents that have the value of the field colour set to "yellow"

bf=colour:yellow^10

Is it possible?

Andrei Stefan
  • 51,654
  • 6
  • 98
  • 89
Belsen
  • 313
  • 3
  • 4
  • 17

1 Answers1

1

With edismax, you can do this:

bf=if(exists(query({!v='colour:yellow'})),10,1)

which is a function query.

Ref:

arun
  • 10,685
  • 6
  • 59
  • 81