Expand my Community achievements bar.

Dive into Adobe Summit 2024! Explore curated list of AEM sessions & labs, register, connect with experts, ask questions, engage, and share insights. Don't miss the excitement.
SOLVED

Find if any parent folder is un-published

Avatar

Level 4

I have a requirement where if someone is trying to activate/publish a child folder, I will call the preprocessor and check whether all parent folder to that child is active or not.

if any of the parents is inactive, I will stop the child folder activation. 

 

Problem - Is there a way to use X-path or SQL query to check for all the parent folder activation.

I am able to check for all parents using the recursive function and its working fine but wanted to check if is there any X-path or SQL or any other simple way to do this.

 

1 Accepted Solution

Avatar

Correct answer by
Community Advisor

Hi,

Queries may not work in this use case and can be expensive also

Recursion make sense here to just immediate parent(s)



Arun Patidar

View solution in original post

1 Reply

Avatar

Correct answer by
Community Advisor

Hi,

Queries may not work in this use case and can be expensive also

Recursion make sense here to just immediate parent(s)



Arun Patidar