I've been developing a web-app in VB.Net which uses CMIS.Net, linking to a FileNet repository. The application builds up queries programmatically, locating documents by creating queries which contain multiple IN_FOLDER statements. In development I had written code to bundle 30 such statements into a query, and successfully processed many such "bundles-of-30" queries from a total list of 299 folders. The application failed on the final bundle, which happened to have 29 IN_FOLDER statements. It turns out that the IN_FOLDER logic fails when the number of statments is an odd-number larger than 2. This information was provided when my client obtained tech support from Oracle. Examples in which IN_FOLDER returned no records, or returned a large number of records, were found to not affect the pass or fail. It appears to be only the "even/odd" condition. I did not find this behaviour documented anywhere (Google search "CMIS IN_FOLDER fail"), and this forum seems like a good place to make it known. Here is an example of a query that works:
SELECT SecurityFolder, cmisbjectId, cmis:name FROM cmis:document WHERE (
IN_FOLDER('idf_50FFF254-0000-CF1E-9CC1-F6EB1F58A770') OR
IN_FOLDER('idf_90FFF254-0000-CA1F-9DB4-AC5E955E4D2D') OR
IN_FOLDER('idf_0002F354-0000-C01C-8FD8-B6F5CB33F543') OR
IN_FOLDER('idf_5002F354-0000-CC16-A7ED-F8D60E733394') OR
IN_FOLDER('idf_B002F354-0000-CE1D-8554-55998AFE4F03') OR
IN_FOLDER('idf_0003F354-0000-C417-8F26-F0F51BDE7D5A') OR
IN_FOLDER('idf_4003F354-0000-CC1A-9C77-6E9EE3E6A00D') OR
IN_FOLDER('idf_9003F354-0000-CF17-A5BA-4C1C4A8FD3C0') OR
IN_FOLDER('idf_E003F354-0000-C913-9F84-7D3BA292AB65') OR
IN_FOLDER('idf_3004F354-0000-CF1B-99E8-89964AF2480D')) Order By SecurityFolder
Are you asking how to create your CMIS query to access FileNet, not Alfresco?
The query is for CMIS to access FileNet. I posted this because I didn't find out about this "bug" anywhere else and I thought it might apply to other developers. There is a lot of useful advice on the site, so it seemed like a natural home for it. Apologies if I didn't make it clear.
Ask for and offer help to other Alfresco Content Services Users and members of the Alfresco team.
Related links:
By using this site, you are agreeing to allow us to collect and use cookies as outlined in Alfresco’s Cookie Statement and Terms of Use (and you have a legitimate interest in Alfresco and our products, authorizing us to contact you in such methods). If you are not ok with these terms, please do not use this website.