You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by Yonik Seeley <yo...@lucidimagination.com> on 2009/09/24 00:10:57 UTC

Re: java doc error local params syntax for dismax

On Wed, Sep 23, 2009 at 5:59 PM, Naomi Dushay <nd...@stanford.edu> wrote:
> The javadoc for  DisMaxQParserPlugin states:
>
> {!dismax qf=myfield,mytitle^2}foo creates a dismax query
>
> but actually, that gives an error.
>
> The correct syntax is
>
> {!dismax qf="myfield mytitle^2"}foo
>
> (could use single quote instead of double quote).

Thanks, I always forget that dismax uses space separated, not comma
separated lists.

-Yonik

Re: java doc error local params syntax for dismax

Posted by Naomi Dushay <nd...@stanford.edu>.
Okay, but

{!dismax qf="myfield mytitle^2"}foo     works

{!dismax qf=myfield mytitle^2}foo     does NOT work

- Naomi

On Sep 23, 2009, at 5:52 PM, Yonik Seeley wrote:

> On Wed, Sep 23, 2009 at 8:24 PM, Naomi Dushay <nd...@stanford.edu>  
> wrote:
>> It's not just the spaces - it's that the quotes (single or double  
>> flavor) is
>> required as well.
>
> LocalParams are space delimited, so the original example would have
> worked if the dismax parser accepted comma delimited fields.
>
> -Yonik
> http://www.lucidimagination.com
>
>
>
>> On Sep 23, 2009, at 3:10 PM, Yonik Seeley wrote:
>>
>>> On Wed, Sep 23, 2009 at 5:59 PM, Naomi Dushay <nd...@stanford.edu>
>>> wrote:
>>>>
>>>> The javadoc for  DisMaxQParserPlugin states:
>>>>
>>>> {!dismax qf=myfield,mytitle^2}foo creates a dismax query
>>>>
>>>> but actually, that gives an error.
>>>>
>>>> The correct syntax is
>>>>
>>>> {!dismax qf="myfield mytitle^2"}foo
>>>>
>>>> (could use single quote instead of double quote).
>>>
>>> Thanks, I always forget that dismax uses space separated, not comma
>>> separated lists.
>>>
>>> -Yonik
>>
>>


Re: java doc error local params syntax for dismax

Posted by Yonik Seeley <yo...@lucidimagination.com>.
On Wed, Sep 23, 2009 at 8:24 PM, Naomi Dushay <nd...@stanford.edu> wrote:
> It's not just the spaces - it's that the quotes (single or double flavor) is
> required as well.

LocalParams are space delimited, so the original example would have
worked if the dismax parser accepted comma delimited fields.

-Yonik
http://www.lucidimagination.com



> On Sep 23, 2009, at 3:10 PM, Yonik Seeley wrote:
>
>> On Wed, Sep 23, 2009 at 5:59 PM, Naomi Dushay <nd...@stanford.edu>
>> wrote:
>>>
>>> The javadoc for  DisMaxQParserPlugin states:
>>>
>>> {!dismax qf=myfield,mytitle^2}foo creates a dismax query
>>>
>>> but actually, that gives an error.
>>>
>>> The correct syntax is
>>>
>>> {!dismax qf="myfield mytitle^2"}foo
>>>
>>> (could use single quote instead of double quote).
>>
>> Thanks, I always forget that dismax uses space separated, not comma
>> separated lists.
>>
>> -Yonik
>
>

Re: java doc error local params syntax for dismax

Posted by Naomi Dushay <nd...@stanford.edu>.
It's not just the spaces - it's that the quotes (single or double  
flavor) is required as well.


On Sep 23, 2009, at 3:10 PM, Yonik Seeley wrote:

> On Wed, Sep 23, 2009 at 5:59 PM, Naomi Dushay <nd...@stanford.edu>  
> wrote:
>> The javadoc for  DisMaxQParserPlugin states:
>>
>> {!dismax qf=myfield,mytitle^2}foo creates a dismax query
>>
>> but actually, that gives an error.
>>
>> The correct syntax is
>>
>> {!dismax qf="myfield mytitle^2"}foo
>>
>> (could use single quote instead of double quote).
>
> Thanks, I always forget that dismax uses space separated, not comma
> separated lists.
>
> -Yonik