jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alexander Klimetschek <aklim...@day.com>
Subject Re: How to do this JCR XPath query
Date Wed, 28 Apr 2010 19:35:54 GMT
2010/4/28 Fran├žois Cassistat <f@maya-systems.com>:
> //element(*, my:type)[... and element(*, my:othertype)[@someattribute='somevalue' and
@someotherattribute='someothervalue'] and ...]

Not sure what exactly you want to do, but if you want to search for
child nodes of type "my:othertype" below nodes of type "my:type", this
should do it:

//element(*, my:type)[@attribute='foo']/element(*,
my:othertype)[@someattribute='somevalue' and

element(*, type) from JCR can be used as a standard location step in
xpath queries.

Hopt that helps,

Alexander Klimetschek

View raw message