[ 
https://issues.apache.org/jira/browse/LUCENE-6249?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14322802#comment-14322802
 ] 

Dawid Weiss edited comment on LUCENE-6249 at 2/16/15 2:25 PM:
--------------------------------------------------------------

The problem doesn't seem to be with the grammar, but with query building after 
the parse tree is acquired.

The tree is fine:
{code}
<modifier operation='MOD_NOT'>
<field start='9' end='12' field='summary' text='foo'/>
</modifier>
{code}

but it eventually goes to a single ModifierQueryNodeBuilder which just returns 
the unmodified underlying query. I don't fully understand the parser, looking 
into it.


was (Author: dweiss):
QueryParser doesn't support multifields.

> StandardQueryParser doesn't support pure negative clauses
> ---------------------------------------------------------
>
>                 Key: LUCENE-6249
>                 URL: https://issues.apache.org/jira/browse/LUCENE-6249
>             Project: Lucene - Core
>          Issue Type: Bug
>    Affects Versions: 4.10.3
>            Reporter: Dawid Weiss
>
> At first I thought it's by design but Uwe says it's a bug. SQP emits this:
> {code}
> StandardQueryParser qp = new StandardQueryParser();
> qp.setDefaultOperator(Operator.AND);
>    
> System.out.println(qp.parse("summary:foo", "deffld"));
> System.out.println(qp.parse("-summary:foo", "deffld"));
> System.out.println(qp.parse("!summary:foo", "deffld"));
> System.out.println(qp.parse("NOT summary:foo", "deffld"));
> {code}
> {code}
> summary:foo
> summary:foo
> summary:foo
> summary:foo
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to