09-04-2023 12:09 PM
What is the best way to retrieve nodes with specific category within a site with java code ?
I had thought of separate lucene queries one behind the other , the first query to retrieve all nodes with that category and the second to analyze if the nodes in the first query are learners of the site node.
The queries seem a bit cumbersome to me and I was wondering if there was a smarter method or some alfresco service that I missed.
If anyone has any suggestions let me know.
09-07-2023 07:12 AM
Use Alfresco's Java API: The Java-backed webscripts allow you to run Java code that can leverage Alfresco's services. FQL (Alfresco Full Text Query Language): FQL is powerful and allows you to combine multiple conditions. It might let you retrieve nodes with a specific category within a site in one query instead of chaining two Lucene queries. NodeService & SearchService: Use NodeService to fetch properties or child associations and SearchService to execute your queries. Use CMIS: Alfresco supports CMIS (Content Management Interoperability Services). You can use CMIS queries to fetch nodes based on conditions.
09-07-2023 07:12 AM
Use Alfresco's Java API: The Java-backed webscripts allow you to run Java code that can leverage Alfresco's services. FQL (Alfresco Full Text Query Language): FQL is powerful and allows you to combine multiple conditions. It might let you retrieve nodes with a specific category within a site in one query instead of chaining two Lucene queries. NodeService & SearchService: Use NodeService to fetch properties or child associations and SearchService to execute your queries. Use CMIS: Alfresco supports CMIS (Content Management Interoperability Services). You can use CMIS queries to fetch nodes based on conditions.
Explore our Alfresco products with the links below. Use labels to filter content by product module.