Implement search priority without losing relvancy


Hello evryone,

Over a full text search I also need to implement that articles configured in a back-end with the checkbox has_search_priority to true, will come before any other article without has_search_priority on the same text search.

Anyone has an idea how to do this?

(Adrien Grand) #2

It seems to me that you could sort by has_search_priority then _score.

    "sort" : [
        { "has_search_priority" : "desc" },

(system) #3