chemistry-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Florian Müller <florian.muel...@alfresco.com>
Subject Re: Problem executing JOIN query in combination with IN_TREE or IN_FOLDER
Date Tue, 01 Feb 2011 11:48:52 GMT
Hi Geert,

First of all, this an Alfresco question and not an OpenCMIS question. The Alfresco CMIS forum
would be a better place for those kind of issues.

Your query is missing a qualifier parameter in the IN_TREE function. This parameter is mandatory
for queries that do JOINs.
(See CMIS specification section "2.1.10.2.4.6 IN_TREE() predicate function".)


Regards,

Florian



On 01/02/2011 11:30, Geert Vanheusden wrote:
> Hi all,
> 
> We get the following error when executing a query:
> 
> org.alfresco.scripts.ScriptException: 01010002 Failed to execute script 'classpath*:alfresco/templates/webscripts/org/alfresco/cmis/queries.post.cmisquery.js':
01010001 Selector must be specified for child constraint (IN_TREE) and join
> 	at org.alfresco.repo.jscript.RhinoScriptProcessor.execute(RhinoScriptProcessor.java:194)
> 	at org.alfresco.repo.processor.ScriptServiceImpl.executeScript(ScriptServiceImpl.java:282)
> 	at org.alfresco.repo.web.scripts.RepositoryScriptProcessor.executeScript(RepositoryScriptProcessor.java:102)
> 	at org.springframework.extensions.webscripts.AbstractWebScript.executeScript(AbstractWebScript.java:981)
> 	at org.springframework.extensions.webscripts.DeclarativeWebScript.execute(DeclarativeWebScript.java:86)
> 
> 
> This is caused by the following query:
> 
> SELECT DOCUMENT.*, EMPLOYEEDOCUMENT.* FROM park:document AS DOCUMENT JOIN park:employeeDocument
AS EMPLOYEEDOCUMENT ON DOCUMENT.cmis:objectId = EMPLOYEEDOCUMENT.cmis:objectId WHERE (IN_TREE('workspace://SpacesStore/89fbb2b2-2992-4104-9cec-cd2c15fb95e7')
AND DOCUMENT.cmis:objectId IN ('workspace://SpacesStore/f0e7d3e7-cb74-4993-ad61-87042ca6de72'))
> 
> This query contains JOIN predicates because we are using aspects, supported by the alfresco
CMIS implementation. We use the "Alfresco OpenCMIS Extension" library (found here: http://cmis.alfresco.com:8080/alfresco-opencmis-extension.html)
to easily add and remove aspects in our code.
> 
> We were wondering if this is a problem with our query or if this is a bug in Alfresco.
> 
> Thanks in advance.
> 
> -- Geert&  Mano
> 
> 
> _________________________________________________
> 
>   We published a new company movie featuring YOU!
>           See http://www.aca-it.be/movie
> _________________________________________________


Mime
View raw message