jackrabbit-oak-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Rajeev Duggal (JIRA)" <j...@apache.org>
Subject [jira] [Created] (OAK-3769) Issue with jcr:contains on tags property
Date Fri, 11 Dec 2015 13:21:10 GMT
Rajeev Duggal created OAK-3769:
----------------------------------

             Summary: Issue with jcr:contains on tags property
                 Key: OAK-3769
                 URL: https://issues.apache.org/jira/browse/OAK-3769
             Project: Jackrabbit Oak
          Issue Type: Bug
          Components: lucene
    Affects Versions: 1.2.8, 1.2.7
            Reporter: Rajeev Duggal


Running the below query, results in Exception pointed by [1]

/jcr:root/content/dam//element(*,dam:Asset)[jcr:contains(jcr:content/metadata/@cq:tags, 'stockphotography:business/business_abstract')]
order by @jcr:created descending

Also if you remove the node at /oak:index/damAssetLucene/indexRules/dam:Asset/properties/cqTags
 and re-index the /oak:index/damAssetLucene index, the query works.

Seems '/' is special character and needs to be escaped by Oak.

[1]
Caused by: org.apache.lucene.queryparser.flexible.core.QueryNodeParseException: Syntax Error,
cannot parse stockphotography\:business/business_abstract: Lexical error at line 1, column
45.  Encountered: <EOF> after : "/business_abstract" 
at org.apache.lucene.queryparser.flexible.standard.parser.StandardSyntaxParser.parse(StandardSyntaxParser.java:74)
at org.apache.lucene.queryparser.flexible.core.QueryParserHelper.parse(QueryParserHelper.java:250)
at org.apache.lucene.queryparser.flexible.standard.StandardQueryParser.parse(StandardQueryParser.java:168)
at org.apache.jackrabbit.oak.plugins.index.lucene.LucenePropertyIndex.tokenToQuery(LucenePropertyIndex.java:1260)
... 138 common frames omitted
Caused by: org.apache.lucene.queryparser.flexible.standard.parser.TokenMgrError: Lexical error
at line 1, column 45.  Encountered: <EOF> after : "/business_abstract"
at org.apache.lucene.queryparser.flexible.standard.parser.StandardSyntaxParserTokenManager.getNextToken(StandardSyntaxParserTokenManager.java:937)
at org.apache.lucene.queryparser.flexible.standard.parser.StandardSyntaxParser.jj_scan_token(StandardSyntaxParser.java:945)
at org.apache.lucene.queryparser.flexible.standard.parser.StandardSyntaxParser.jj_3R_4(StandardSyntaxParser.java:827)
at org.apache.lucene.queryparser.flexible.standard.parser.StandardSyntaxParser.jj_3_2(StandardSyntaxParser.java:739)
at org.apache.lucene.queryparser.flexible.standard.parser.StandardSyntaxParser.jj_2_2(StandardSyntaxParser.java:730)
at org.apache.lucene.queryparser.flexible.standard.parser.StandardSyntaxParser.Clause(StandardSyntaxParser.java:318)
at org.apache.lucene.queryparser.flexible.standard.parser.StandardSyntaxParser.ModClause(StandardSyntaxParser.java:303)
at org.apache.lucene.queryparser.flexible.standard.parser.StandardSyntaxParser.ConjQuery(StandardSyntaxParser.java:234)
at org.apache.lucene.queryparser.flexible.standard.parser.StandardSyntaxParser.DisjQuery(StandardSyntaxParser.java:204)
at org.apache.lucene.queryparser.flexible.standard.parser.StandardSyntaxParser.Query(StandardSyntaxParser.java:166)
at org.apache.lucene.queryparser.flexible.standard.parser.StandardSyntaxParser.TopLevelQuery(StandardSyntaxParser.java:147)
at org.apache.lucene.queryparser.flexible.standard.parser.StandardSyntaxParser.parse(StandardSyntaxParser.java:65)
... 141 common frames omitted



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

Mime
View raw message