AnsweredAssumed Answered

Simple CMIS query not working

Question asked by leonardo.celati on Jun 21, 2014
Latest reply on Jun 25, 2014 by leonardo.celati
I have a simple CMIS query which I am executing from within a collection folder. The purpose is to retrieve two specific documents placed in two different folders.


SELECT d.* FROM cmis:document d JOIN ws:webasset w ON w.cmis:objectId = d.cmis:objectId
WHERE
   (d.cmis:name = 'name1.html' AND in_folder('${section:/root/folder1}'))
OR
   (d.cmis:name = 'name2.html' AND in_folder('${section:/root/folder2}'))


I also gave a try to:


SELECT d.* FROM cmis:document d JOIN ws:webasset w ON w.cmis:objectId = d.cmis:objectId
WHERE
   (d.cmis:name = 'name1' OR d.cmis:name = 'name2.html')
AND
   (in_folder('${section:/root/folder1}') OR in_folder('${section:/root/folder2}'))


but they are not retrieving any documents. If I am executing just (name1 in folder1) alone it correctly retrieve the documents.
Am I missing some fundamental from CMIS language ?

Related question: I used to execute this type of query directly from the collection folder, due to the presence of in_folder() or in_tree() with the addition of $section instruction, which are not working in node browser. Is there a way to execute this in node browser ?

Outcomes