Hello,

I’m experimenting with streaming expressions and I wonder how to escape a 
double quote in a value.
I am on 7.3.0 and trying with the text area on 
http://localhost:8983/solr/#/collname/stream

The following expression works for me and returns results:
search(kmm, q="sds_endpoint_name:F2", fl="sds_endpoint_name", 
sort="sds_endpoint_name ASC", qt="/export“)

When I try to add a double quote to the value quoted with a backslash like 
this: 
search(kmm, q="sds_endpoint_name:F\"2", fl="sds_endpoint_name", 
sort="sds_endpoint_name ASC", qt="/export")
I get an exception with message:

org.apache.solr.search.SyntaxError:  Cannot parse 'sds_endpoint_name:F\"2': 
Lexical error at line 1, column 22.  Encountered:  after : \"\\\"2\“",

I tried several more levels of escaping with backslashes but none worked so far
(only the error message was different as sometimes the expression was broken in 
different ways)


On http://localhost:8983/solr/#/collname/query, entering
sds_endpoint_name:F\“2
as the q parameter does not throw a syntax error and an empty result is returned
(which is to be expected as there is no document with a quote in the name at 
the moment).


Is there a correct way to escape the double quote in a streaming expression?


Best regards
Christian

Reply via email to