Hi All, I have a custom model and in types definition I have the following definition: <type name="spurocesso"> <title>Processo</title> <parent>cm:folder</parent> <properties> <property name="spurocesso.Numero"> <title>Número</title> <type>d:text</type> </property> <property name="spurocesso.Externo"> <title>Externo?</title> <type>d:boolean</type> </property> . . . My question is how do I build a query using CMIS to check if spurocesso.Externo = 'true'? I made this query but it doesnt like the dot in processo.Externo. SELECT F.cmisbjectId FROM cmis:folder AS F JOIN spurocesso AS P ON F.cmisbjectId = P.cmisbjectId WHERE IN_TREE (F,'workspace://SpacesStore/8571db40-0d85-4fd3-b583-e02a6d43539f') and spurocesso.Externo='false' ORDER BY F.cmis:creationDate DESC
It returns this error: Search failed due to: org.alfresco.cmis.CMISQueryException: 04228045 Unknown column/property Externo
Go look at the type definition for your custom aspect (using a tool like OpenCMIS Workbench or a client library) and check (1) that the property is queryable and (2) that you are using the query name which could be different than the actual property name. (Especially with your non-alphanumeric character in the property name).
For example, using my SomeCo examples, I can successfully query in the sc:isActive boolean property like this:
<blockcode> SELECT * FROM cmis:document as D join sc:webable as W on D.cmisbjectId = W.cmisbjectId where W.sc:isActive = true </blockcode> Jeff
Hi Jeff, thank you for your answer but unfortunately we faced this problem after the whole application is already developed and we have to keep the non-alpha character. We are using CONTAINS(P, 'spurocesso.Externo: \'false\'') but is getting slower and now I know it isnt the right function to use once this isnt text to be searched. Following our model I tried 'P.Externo:isActive' but it didnt work because I have its name as ":spu.processo.Externo" like is showed in the definition I pasted. Do you think there is another way?