Page 1 of 1

CMIS query - how to search for document content?

Posted: Mon Nov 27, 2017 8:06 pm
by fpvolquind
Hi!
I am trying to use LogicalDOC as the document repository for an application in Java. I can properly connect to the CMIS Atompub interface, and query for document name. How do I build a query so it searches for document content as well? Also, how do I return search matching score?

For example, on Alfresco, I use the following syntax:

Code: Select all

SELECT cmis:name, cmis:objectId, SCORE () FROM cmis:document WHERE IN_FOLDER('fld.folderID') AND (CONTAINS('keyword') OR cmis:name LIKE '%keyword%') ORDER BY SEARCH_SCORE DESC
Also, on Apache CMIS Workbench, the query returns only a single column; I had to change it to "SELECT * FROM ..." to return other columns. Is this a bug?

Thanks for your attention.

Re: CMIS query - how to search for document content?

Posted: Fri Dec 01, 2017 12:36 pm
by agaspa
Hi fpvolquind,
I think that definitely there is something clanking with the CMIS implementation of LogicalDOC even tough it uses Apache Chemistry OpenCMIS

Perhaps something can be fixed, but the CMIS module it's quite delicate, because it is used by other external modules/software.
I found however that if you remove the spaces in the select arguments you can see more columns (but not the SCORE())
In attachment you can find the results of my tests