So I need to explicitly set the boosts in the query?

ie

q=+(field1:this^2 field1:"that thing"^4) +(field2:other^3)



---

IntelCompute
Web Design & Local Online Marketing

http://www.intelcompute.com

On Mon, 5 Dec 2011 09:49:34 -0300, Tomás Fernández Löbbe
<tomasflo...@gmail.com> wrote:
> In this case, the boost and fields in the "qf" parameter won't be
> considered for the search. With this query Solr will search for documents
> with the terms "this" and/or (depending on your default operator) "that" in
> the field1 and the term "other" in the field2
> 
> On Mon, Dec 5, 2011 at 9:44 AM, Robert Brown <r...@intelcompute.com> wrote:
> 
>> Thanks Tomás,
>>
>> My example should have read...
>>
>> q=+(field1:this field1:that) +(field2:other)
>>
>> I'm using edismax.
>>
>> so with this approach, the boosts as specified in solrconfig qf will
>> remain in place?
>>
>>
>> ---
>>
>> IntelCompute
>> Web Design & Local Online Marketing
>>
>> http://www.intelcompute.com
>>
>> On Mon, 5 Dec 2011 09:17:59 -0300, Tomás Fernández Löbbe
>> <tomasflo...@gmail.com> wrote:
>> > Hi Robert, the answer depends on the query parser you are using. If you
>> are
>> > using the "edismax" query parser, then the "qf" will only be used when
>> you
>> > don't specify any field in the "q" parameter. In your example the result
>> > query will be, boolean queries for "this" and "that" in the field1 and a
>> > DisMax query for the term "other" in fields (and the boost) you specify
>> in
>> > qf.
>> >
>> > If you use "dismax" the field in the query will not be considered and if
>> > you use LuceneQP the qf are not considered and it is going to use the
>> > default search field for the term "other" and no boost.
>> >
>> > You can see this very easily turning on the "debugQuery".
>> >
>> > Regards,
>> >
>> > Tomás
>> >
>> > On Mon, Dec 5, 2011 at 8:18 AM, Robert Brown <r...@intelcompute.com>
>> wrote:
>> >
>> >> If I have a set list in solrconfig for my "qf" along with their boosts,
>> >> and I then specify field names directly in q (where I could also
>> override
>> >> the boosts), are the boosts left in place, or reset to 1?
>> >>
>> >>
>> >> <str name="qf">
>> >>  this^3
>> >>  that^2
>> >>  other^9
>> >> </str>
>> >>
>> >>
>> >> ie q=field1:+(this that) +(other)
>> >>
>> >>
>> >>
>> >>
>> >>
>> >> --
>> >>
>> >> IntelCompute
>> >> Web Design & Local Online Marketing
>> >>
>> >> http://www.intelcompute.com
>> >>
>> >>
>>
>>

Reply via email to