Amir Mistric
2007-06-19 00:46:37 UTC
Hi
I am a bit new to Xpath in Jackrabbit but can someone tell me what is the difference between these 3 queries:
Q1: //*[@jcr:primaryType='mgnl:content']//*[jcr:contains(.,'term1') and jcr:contains(., 'term2')]
Q2: //*[@jcr:primaryType='mgnl:content' and jcr:contains(.,'term1') and jcr:contains(.,'term2')]
Q3: //element(*,nt:base)[@jcr:primaryType='mgnl:content' and jcr:contains(.,'term1') and jcr:contains(.,'term2')]
Basically all I want is to extract all the nodes of primary type "mgnl:content" and then to search them for the query terms which a
I am a bit new to Xpath in Jackrabbit but can someone tell me what is the difference between these 3 queries:
Q1: //*[@jcr:primaryType='mgnl:content']//*[jcr:contains(.,'term1') and jcr:contains(., 'term2')]
Q2: //*[@jcr:primaryType='mgnl:content' and jcr:contains(.,'term1') and jcr:contains(.,'term2')]
Q3: //element(*,nt:base)[@jcr:primaryType='mgnl:content' and jcr:contains(.,'term1') and jcr:contains(.,'term2')]
Basically all I want is to extract all the nodes of primary type "mgnl:content" and then to search them for the query terms which a