I have a very simple schema: two integers and two text fields.

<fields>
<field name="answer_id" type="integer" indexed="true" stored="true" required="true" />
   <field name="question" type="text" indexed="true" stored="true"/>
<field name="question_source" type="integer" indexed="true" stored="true"/>
   <field name="answer" type="text" indexed="true" stored="false"/>
</fields>

I want to do full text searching on the text fields as normal. However, I want to boost all documents where question_source == 3 to the top. How do I do that?

So the results should be:

All documents where question_source == 3 first, sorted by relevance in the text fields.

All other documents sorted by text field relevance.

How do I achieve this?

-jsd-

Reply via email to