jackrabbit-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bertrand LEGA <legabertr...@yahoo.fr>
Subject XPATH query : how to find node not having a specific attribute
Date Thu, 02 Jun 2005 09:05:15 GMT


I'm trying to find all the unlocked nodes in my jcr with a query.
If a node is locked, the property jcr:lockOwner is created and holds the 
id of the user who locks the node.
And if the node is not locked, this property doesn't exist.

Of course, my mode implement mix:lockable.

My question is how to write my query to retreive the unlocked nodes (ie 
those without the attribute jcr:lockOwner) ?
//*[@jcr:lockOwner = null] doesn't seem to work.

I noticed there is a IS NOT NULL and IS NULL clause in the SQL language. 
Is there anything alike in XPATH ?

Any idea ?

Have a nice day,
Bertrand LEGA.

View raw message