cancel
Showing results for 
Search instead for 
Did you mean: 

get the number of files of each type

defrancile
Champ in-the-making
Champ in-the-making
Hello, I need to get the number of files of each type. I have n models and in each one I have n types.
I have tried the solution that says here https://angelborroy.wordpress.com/2014/07/15/alfresco-%C2%B7-counting-elements-by-cmis-queries/ But I'm not going or I do not know what to putin this select:
SELECT cmis: objectId FROM cmis: document where IN_TREE ('[ID]') and cmis: objectTypeId = 'D: ks: docType';  I need help! Thank you
3 REPLIES 3

kalpesh_c2
Star Collaborator
Star Collaborator

Are you using CMIS ?
Please refer this documentation   you can also use lucene query to search all document by type , within alfresco or within a path of your search folder .

Thanks,
Kalpesh

cesarista
World-Class Innovator
World-Class Innovator

Hi:

From database point of view you can check the following link:

https://blog.dbi-services.com/alfresco-some-useful-database-queries/ 

Regards.

--C.

cesarista
World-Class Innovator
World-Class Innovator

Hi:

And you can use CMIS workbench for getting these numbers for your document types with a groovy script. There is a demo example script for CMIS SQL queries included in CMIS workbench.

Apache Chemistry - CMIS Workbench 

Regards.

--C.