내 커뮤니티 업적 표시줄을 확대합니다.

Submissions are now open for the 2026 Adobe Experience Maker Awards.

Mark Solution

활동이 없어 이 대화는 잠겼습니다. 새 게시물을 작성해 주세요.

해결됨

CQ 5.3 QueryBuilder Search Not Working as Expected

Avatar

Level 1

Hi,

I'm trying to produce a query that will return all pages under a path where a property is NOT present.

Effectively I want the query builder query that will produce the following xpath: /jcr:root/content/site/my/path//element(*, cq:Page)[not(jcr:content/task/@finished)]

For CQ 5.3 the 'exists' property doesn't seem to be present (according to the docs: http://docs.adobe.com/docs/en/cq/5-3/javadoc/com/day/cq/search/eval/JcrPropertyPredicateEvaluator.ht...), however it looks like I can use 'not', so I've tried the following two examples but neither work as I expect in query debugger:

#1

path=/content/site/my/path
type=cq:Page
property=jcr:content/task/finished
property.operation=not

#2

path=/content/site/my/path
type=cq:Page
property=jcr:content/task/finished
property.operation=not
property.value=true

I've also seen pages that suggest these should work, and I can't seem to see any hotfixes that would cover fixing this (assuming it isn't actually working correctly).

Can anyone offer a solution or point out where I'm going wrong?

Using CQ 5.3, upgraded to crx 2.2.

Cheers

Chris

1 채택된 해결책 개

Avatar

정확한 답변 작성자:
Level 10

For this - i recommend using the AEM Test Query Tool:

http://cq-ops.tumblr.com/post/23543240500/how-to-use-cqs-query-debugger-tool

Try different combinations to get the correct query. 

원본 게시물의 솔루션 보기

2 답변 개

Avatar

정확한 답변 작성자:
Level 10

For this - i recommend using the AEM Test Query Tool:

http://cq-ops.tumblr.com/post/23543240500/how-to-use-cqs-query-debugger-tool

Try different combinations to get the correct query. 

Avatar

Level 1

I wouldn't have posted here without doing that first.