Get document by query with all properties without content stream

cancel
Showing results for 
Search instead for 
Did you mean: 
mundifaber
Member II

Get document by query with all properties without content stream

Hello,

At the moment I'm getting Alfresco documents by queries like that:

select cmis:objectId from cmis:document ...

then I get the document itself by the following code:

String objectId = qresult.getPropertyValueByQueryName("d.cmis:objectId");
Document doc = (Document) session.getObject(session.createObjectId(objectId));

The problem is that when I get the document like that it seems to transfer the whole contentStream for every document which is not needed in my use-case.

Then I tried to get all properties by changing the query to:

select * from cmis:document

but this returns only the properties of the document aspect (cmis:name, ...) is it possible to get all properties of the document without having to add all aspect with a "join" to the query?

Or is there another way to get documents with all properties but without the contentstream?

 

1 Reply
jpotts
Professional

Re: Get document by query with all properties without content stream