You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by "Shawn Heisey (JIRA)" <ji...@apache.org> on 2018/02/21 08:30:00 UTC
[jira] [Comment Edited] (SOLR-11156) Edismax query parser fails to
parse q=(*:*)
[ https://issues.apache.org/jira/browse/SOLR-11156?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16371085#comment-16371085 ]
Shawn Heisey edited comment on SOLR-11156 at 2/21/18 8:29 AM:
--------------------------------------------------------------
With 7.2.1, on the default configset and querying with defType=edismax, I see similar behavior when the *:* query is wrapped in parentheses:
{noformat}
"debug":{
"rawquerystring":"(*:*)",
"querystring":"(*:*)",
"parsedquery":"+DisjunctionMaxQuery((_text_:*\\:*))",
"parsedquery_toString":"+(_text_:*\\:*)",
"explain":{},
"QParser":"ExtendedDismaxQParser",
{noformat}
I'm not really sure whether this should be considered a bug or not. The lucene parser handles it like you're expecting, and there's a strong argument that edismax should correctly handle virtually anything the lucene parser can.
I'm pretty sure that the reason this fails is that the \*:\* query is special syntax, and it only gets correctly interpreted if the entire query clause is *exactly* those three characters. By enclosing it in parentheses, the query clause does not precisely match the special syntax.
was (Author: elyograg):
With 7.2.1, on the default configset and querying with defType=edismax, I see similar behavior when the *:* query is wrapped in parentheses:
{noformat}
"debug":{
"rawquerystring":"(*:*)",
"querystring":"(*:*)",
"parsedquery":"+DisjunctionMaxQuery((_text_:*\\:*))",
"parsedquery_toString":"+(_text_:*\\:*)",
"explain":{},
"QParser":"ExtendedDismaxQParser",
{noformat}
I'm not really sure whether this should be considered a bug or not. The lucene parser handles it like you're expecting, and there's a strong argument that edismax should correctly handle virtually anything the lucene parser can.
I'm pretty sure that the reason this fails is that the *:* query is special syntax, and it only gets correctly interpreted if the entire query clause is *exactly* those three characters. By enclosing it in parentheses, the query clause does not precisely match the special syntax.
> Edismax query parser fails to parse q=(*:*)
> -------------------------------------------
>
> Key: SOLR-11156
> URL: https://issues.apache.org/jira/browse/SOLR-11156
> Project: Solr
> Issue Type: Bug
> Security Level: Public(Default Security Level. Issues are Public)
> Components: query parsers
> Affects Versions: 5.5.1
> Environment: Solr 5.5.1
> Reporter: Alfonso Noriega Meneses
> Priority: Major
> Labels: edismax, query-parser, solr
>
> The Edismax query parser does parse the query {{(\*:\*)}} as a exact text match instead of a match all documents.
> Setting the debugQuery param to true and the query {{\*:\*}} we get this json:
> {code}
> "debug": {
> "rawquerystring": "*:*",
> "querystring": "*:*",
> "parsedquery": "(+MatchAllDocsQuery(*:*))/no_coord",
> "parsedquery_toString": "+*:*",
> ...
> }
> {code}
> But with the query {{(\*:\*)}} the Edismax query parser returns a {{DisjunctionMaxQuery}} like shown in the following json:
> {code}
> "debug": {
> "rawquerystring": "(*:*)",
> "querystring": "(*:*)",
> "parsedquery": "(+DisjunctionMaxQuery((text:*\\:*)))/no_coord",
> "parsedquery_toString": "+(text:*\\:*)",
> "explain": {},
> "QParser": "ExtendedDismaxQParser",
> ...
> }
> {code}
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org