[
https://issues.apache.org/jira/browse/STANBOL-678?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Rupert Westenthaler resolved STANBOL-678.
-----------------------------------------
Resolution: Fixed
fixed with revision 1359206 in the trunk and then entityhub.0.10 branch
> SolrYard needs to quote search terms like "OR" "AND" "NOT"
> ----------------------------------------------------------
>
> Key: STANBOL-678
> URL: https://issues.apache.org/jira/browse/STANBOL-678
> Project: Stanbol
> Issue Type: Bug
> Reporter: Rupert Westenthaler
> Assignee: Rupert Westenthaler
> Priority: Minor
>
> Queries for keywords used by Solr do create exceptions like
> Caused by: org.apache.lucene.queryParser.ParseException: Cannot parse
> '(((@de/skos\:prefLabel/:MVVM)) OR ((@/skos\:prefLabel/:MVVM)) OR
> ((@de/skos\:prefLabel/:OR)) OR ((@/skos\:prefLabel/:OR)))': Encountered "
> <OR> "OR "" at line 1, column 88.
> Was expecting one of:
> "(" ...
> "*" ...
> <QUOTED> ...
> <TERM> ...
> <PREFIXTERM> ...
> <WILDTERM> ...
> "[" ...
> "{" ...
> <NUMBER> ...
>
> at org.apache.lucene.queryParser.QueryParser.parse(QueryParser.java:211)
> at
> org.apache.solr.search.LuceneQParser.parse(LuceneQParserPlugin.java:80)
> [...]
> Even that I can not find in the documentation that one needs to quote queries
> like
> field:OR
> field:AND
> .. possible other ..
> quoting those
>
> field:"OR"
> solves those.
> As there is no disadvantage in quoting all field values that do not contain
> wildcards the best solution seams to be to quote them all.
> NOTE: that the SolrYard already treats queries and tokens that use wildcard
> chars differently.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira