- Published on
 
Difference between jcr:lastModified and cq:lastModified in AEM
- Authors
 
- Name
 - Khalil
 - @Im_Khalil
 
What is a need of having two different dates jcr:lastModified and cq:lastModified in AEM and when which one is used ?
cq:lastModified is present at jcr:content node level, means it is available on all those nodes whose jcr:primaryType is cq:pageContent. Where as at all other nodes types jcr:lastModified is used. In general we can say that if any content is getting modified through aem functionality it will refer and update cq:lastModified and everything else that is using JCR core functionality will refer and update jcr:lastModified. Both properties can’t be present on the same node.
Note:
jcr:content( cq:pageContent ) is a structured node and has a sling:resourceType property which points or refers to the component that contains the sling script which will be used for rendering the content.
You might also like to read
- 1.AEM Dispatcher Series 2 - Understanding the `dispatcher.any` File
 - 2.AEM Dispatcher Series 3 - Securing Your AEM Site - Deep Dive into Dispatcher `/filter` Rules
 - 3.AEM Dispatcher Series 4 - A Developer’s Guide to Dispatcher `/cache` Rules
 - 4.AEM Dispatcher Series 5 - When and How to Clear Cache
 - 5.AEM Dispatcher Series 6 - Handling Vanity URLs, Sessions, and `/renders`