jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Noam Tenne <no...@jfrog.org>
Subject Using wildcards after encoding digits with ISO9075
Date Thu, 26 Feb 2009 11:28:42 GMT

Hello there

A query which I try to execute involves a version number:
/jcr:root/prod/2.7.7/element(*, dummy:file)

After failing with this query I have found out that I need to encode the
digits of the version with ISO9075, which makes the query run properly.

But another problem I am facing is, in a case that I would like to surround
the version number with wildcards (?, %, *). When trying to surround the
encoded (or non-encoded) version with different wildcards, I get an error:

javax.jcr.query.InvalidQueryException: Lexical error at line 1, column 40. 
Encountered: "_" (95), after : "" for statement: for $v in
/jcr:root/prod/*_x0032_.7.7*/element(*, dummy:file) return $v: Lexical error
at line 1, column 17.  Encountered: "_" (95), after : "": Lexical error at
line 1, column 17.  Encountered: "_" (95), after : ""

I know that I can use - element(*)[jcr:like(@dummy:name,'%2.7.7%')] instead
of encoding and surrounding, but was wondering if the failure of the manual
method is a bug?

Thanks

Noam
-- 
View this message in context: http://www.nabble.com/Using-wildcards-after-encoding-digits-with-ISO9075-tp22222274p22222274.html
Sent from the Jackrabbit - Users mailing list archive at Nabble.com.


Mime
View raw message