QueryBuilder to extract specific nodes based on jcr:lastmodified | Community
Skip to main content
Level 9
October 16, 2015
Solved

QueryBuilder to extract specific nodes based on jcr:lastmodified

  • October 16, 2015
  • 4 replies
  • 1357 views

Hello,

Is there a way to pick up nodes of specific resource types eg:foundation/components/text and test/components/textCustom, under a specific path, /content/Test/en_US, and retrieve the ones modified in past 2 days?

Please let me know.

Regards,

NZ

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by Ojjis

You could also use this:
 

map.put("relativedaterange", "@jcr:content/cq:lastModified"); map.put("relativedaterange.lowerBound", "-2d");

for changes made in the last two days :)

Good Luck
/Johan

4 replies

smacdonald2008
Level 10
October 16, 2015

The QueryBuilder API is built on JCR API. Having said that -- see this thread that talks about your use case:

http://jackrabbit.510166.n4.nabble.com/Querying-for-all-modified-nodes-based-on-jcr-lastModified-td517563.html

HTH

Level 9
October 16, 2015

Thanks Scott, had figured it out earlier, appreciate help.

daterange.property=jcr:lastModified
daterange.property.and=true
daterange.lowerBound=2013-09-09
daterange.lowerOperation= >=
daterange.upperBound =2013-09-14

 

Regards,

Nicole

Ojjis
OjjisAccepted solution
Level 7
October 16, 2015

You could also use this:
 

map.put("relativedaterange", "@jcr:content/cq:lastModified"); map.put("relativedaterange.lowerBound", "-2d");

for changes made in the last two days :)

Good Luck
/Johan

Level 2
October 16, 2015

hi,

 

I want to search for assets in the whole Dam just excluding a folder(read expired folder). how can i achieve it.. 

 

please help.

thank you.