Setup: I want to run a JCR-SQL2 query that selects nodes based on an attribute 
of a descendant node.

I have created the query (see below) that does the work, but returns both nodes 
(the ancestor & descendant).  From the googling, “SELECT parent.*” should cause 
the query to only return the ancestors / parent nodes, but I haven’t been able 
to get it to work.

Looking for advice - what am I doing wrong? - or whether anyone else has seen 
this problem.

Thanks
Morrell



Query:

SELECT parent.* FROM [ancestorNodeType] AS parent INNER JOIN 
[descendantNodeType] as child ON ISDESCENDANTNODE(child,parent) WHERE 
child.[descendantProperty] = CAST('true' AS BOOLEAN)


Reply via email to