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 yriveiro <ya...@gmail.com> on 2013/05/28 19:11:22 UTC
Query syntax error: Cannot parse ....
Hi,
When I try run this query,
http://localhost:8983/solr/coreA/select?q=source_id:(7D1FFB# OR 7D1FFB)
city:ES, I have the error below:
<response>
<lst name="responseHeader">
<int name="status">400</int>
<int name="QTime">1</int>
</lst>
<lst name="error">
<str name="msg">
org.apache.solr.search.SyntaxError: Cannot parse 'source_id:(7D1FFB':
Encountered "<EOF>" at line 1, column 43. Was expecting one of: <AND> ...
<OR> ... <NOT> ... "+" ... "-" ... <BAREOPER> ... "(" ... ")" ... "*" ...
"^" ... <QUOTED> ... <TERM> ... <FUZZY_SLOP> ... <PREFIXTERM> ... <WILDTERM>
... <REGEXPTERM> ... "[" ... "{" ... <LPARAMS> ... <NUMBER> ...
</str>
<int name="code">400</int>
</lst>
</response>
How I can fix the query?
Regards
/Yago
-----
Best regards
--
View this message in context: http://lucene.472066.n3.nabble.com/Query-syntax-error-Cannot-parse-tp4066560.html
Sent from the Solr - User mailing list archive at Nabble.com.
Re: Query syntax error: Cannot parse ....
Posted by gpssolr2020 <ps...@gmail.com>.
Hi,
Try to pass URL encode value(%23) for # .
Thanks.
--
View this message in context: http://lucene.472066.n3.nabble.com/Query-syntax-error-Cannot-parse-tp4066560p4066566.html
Sent from the Solr - User mailing list archive at Nabble.com.
Re: Query syntax error: Cannot parse ....
Posted by Yago Riveiro <ya...@gmail.com>.
Hi,
Indeed, with character # encoded the query works fine.
Thanks
--
Yago Riveiro
Sent with Sparrow (http://www.sparrowmailapp.com/?sig)
On Wednesday, May 29, 2013 at 9:43 PM, bbarani wrote:
> # has a separate meaning in URL.. You need to encode that..
>
> http://lucene.apache.org/core/3_6_0/queryparsersyntax.html#Escaping%20Special%20Characters.
>
>
>
> --
> View this message in context: http://lucene.472066.n3.nabble.com/Query-syntax-error-Cannot-parse-tp4066560p4066879.html
> Sent from the Solr - User mailing list archive at Nabble.com (http://Nabble.com).
>
>
Re: Query syntax error: Cannot parse ....
Posted by bbarani <bb...@gmail.com>.
# has a separate meaning in URL.. You need to encode that..
http://lucene.apache.org/core/3_6_0/queryparsersyntax.html#Escaping%20Special%20Characters.
--
View this message in context: http://lucene.472066.n3.nabble.com/Query-syntax-error-Cannot-parse-tp4066560p4066879.html
Sent from the Solr - User mailing list archive at Nabble.com.