Is there a way i can search if any property's value on any node on JCR contains a specific value. EX : I want to get all the nodes which has some propery whose value contains a string "Sample".
I know there is something called "fulltext" property but how do i specify multiple values in the predicate for "type" property as any node whose type can be nt:unstructured, cq:page,cq:pageContent etc can contain the value which contains a string "sample".
Solved! Go to Solution.
Views
Replies
Total Likes
Hi
Please have a look at this reference article for your help:-
Link:- http://aempodcast.com/2015/aem-resources/aem-queries-xpath-jcr-sql2-query-builder-syntaxes/#.V0QAaPl... (point 3)
//
Use fulltext="specific value"
Example:-
1 2 | path=/content fulltext=pants |
1 | /jcr:root/content//element(*)[jcr:contains(@*, 'pants')] |
1 2 3 | SELECT * from [nt:base] AS t where ISDESCENDANTNODE('/content') and contains(t.*, 'pants') |
I hope this will help you.
Thanks and Regards
Kautuk Sahni
Views
Replies
Total Likes
Hi
Please have a look at this reference article for your help:-
Link:- http://aempodcast.com/2015/aem-resources/aem-queries-xpath-jcr-sql2-query-builder-syntaxes/#.V0QAaPl... (point 3)
//
Use fulltext="specific value"
Example:-
1 2 | path=/content fulltext=pants |
1 | /jcr:root/content//element(*)[jcr:contains(@*, 'pants')] |
1 2 3 | SELECT * from [nt:base] AS t where ISDESCENDANTNODE('/content') and contains(t.*, 'pants') |
I hope this will help you.
Thanks and Regards
Kautuk Sahni
Views
Replies
Total Likes