cancel
Showing results for 
Search instead for 
Did you mean: 

CMIS Queries on Nodes Outside of Company Home?

vamirr
Champ on-the-rise
Champ on-the-rise
I'm trying to do some CMIS queries on repository nodes that exist outside of Company Home.


My use case is this: I'd like to calculate some metrics on my users and when their accounts where created.   Each user has a node under the System > People.   These nodes have a child node named 'configurations' that provide a date created. 

I'm using the CMIS search because it allows me provide a date range.   What I'd like is to query the names and count of users created by month for the last three years.

Something similar to:


SELECT * FROM cmis:folder WHERE cmis:name = 'configurations' AND cmis:creationDate > TIMESTAMP '2013-01-01T14:20:00.000-00:00' AND cmis:creationDate < TIMESTAMP '2013-02-01T14:20:00.000-00:00'



My issue is that the javascript search APIs don't seem to accommodate searches outside of company home.  That said, how can I perform similar queries in javascript?
1 REPLY 1

jpotts
World-Class Innovator
World-Class Innovator
Here are a few thoughts:

- Lucene also supports date range searches. You don't need CMIS to do that.
- CMIS doesn't care where in the repository your nodes live. But that configurations folder has to be of type cm:folder or one of its sub-types, including custom types. And the config objects have to be of type cm:content or one of its sub-types, including custom types. For example, objects that inherit directly from sys: and skip cm:content won't be available to CMIS.
- There is a "cmis" root-scoped object available from JavaScript. It was broken in 4.0 community for a while, but I believe it was fixed with 4.2.
- You might want to test your searches in the node browser. You can specify all of the different search syntaxes that the repository supports. Then when you are satisfied your query is working, you can worry about putting it in your code.
- Consider installing Florian Maul's JavaScript console if you have not already.

Jeff