Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

How to specify nested “not” operation in specific group id in AEM?

Anderson_Hamer
Level 4
Level 4

I have a little complex predicator in which I need to have some nested not operation

 

path=/content/course/
type=cq:Page
group.1_daterange.lowerBound=2019-06-12T13:39:19.358Z
group.1_daterange.property=jcr:content/xyz

group.2_daterange.upperBound=2019-06-12T13:39:19.358Z
group.2_daterange.property=jcr:content/abc

group.3_relativedaterange.property=jcr:content/courseStartDate
group.3_relativedaterange.lowerBound=0
group.p.not=true


I don’t want to include the result of group 1 and group 2 hence I am using NOT operation, unfortunately this works at root level, not at level group(n) level. Basically I need to set not operation for group 1 and group 2, like "not(group 1 & group 2) and group 3" Is there any syntax which will do suite my case ?

I tried with below syntax but it is simply ignoring it.

group.1_group.p.not=true
group.2_group.p.not=true
3 Replies
Arun_Patidar
Community Advisor
Community Advisor

try with below query

 

path=/content/course/
type=cq:Page
group.1_group.1_daterange.lowerBound=2019-06-12T13:39:19.358Z
group.1_group.1_daterange.property=jcr:content/xyz

group.1_group.2_daterange.upperBound=2019-06-12T13:39:19.358Z
group.1_group.2_daterange.property=jcr:content/abc

group.1_group.p.not=true

group.2_group.relativedaterange.property=jcr:content/courseStartDate
group.2_group.relativedaterange.lowerBound=0
group.p.and=true

Anderson_Hamer
Level 4
Level 4
No, it is not applying operator on given group id. Posted solution, Please check it
Anderson_Hamer
Level 4
Level 4

I found that we should use nested group in order to specify operation on specific group id

 

path=/content/course/
type=cq:Page
p.limit=-1
1_property=jcr:content/event

group.1_group.1_group.daterange.lowerBound=2019-12-26T13:39:19.358Z
group.1_group.1_group.daterange.property=jcr:content/xyz

group.1_group.2_group.daterange.upperBound=2019-12-26T13:39:19.358Z
group.1_group.2_group.daterange.property=jcr:content/abc

group.1_group.3_group.relativedaterange.property=jcr:content/courseStartDate
group.1_group.3_group.relativedaterange.lowerBound=0
group.1_group.2_group.p.not=true
group.1_group.1_group.p.not=true