OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

cmis message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]


Subject: Re: [cmis] discovering containment relationships in queries


There's two ways of doing it:
1. leverage the repository specific relationship (or parentId property if single) if available (e.g., rep-specific)
2. do two queries:
SELECT ObjectId FROM folder WHERE important = true
SELECT * FROM document WHERE IN_FOLDER(id1) OR IN_FOLDER(id2) ... (or bunch of getChildren calls)

What are the use cases where filtering the folders are required and then getting contained documents in 1 operation is necessary?

-Al

Al Brown
Emerging Standards and Industry Frameworks
CMIS: https://w3.tap.ibm.com/w3ki07/display/ECMCMIS/Home
Industry Frameworks: https://w3.tap.ibm.com/w3ki07/display/ECMIF/Home

Office 714 327 3453
Mobile 714 263 6441
Email albertcbrown@us.ibm.com
CONFIDENTIAL NOTICE: The contents of this message, including any attachments, are confidential and are intended solely for the use of the person or entity to whom the message was addressed. If you are not the intended recipient of this message, please be advised that any dissemination, distribution, or use of the contents of this message is strictly prohibited. If you received this message in error, please notify the sender. Please also permanently delete all copies of the original message and any attached documentation.

Inactive hide details for Florent Guillaume ---07/01/2009 03:12:28 AM---Hi,Florent Guillaume ---07/01/2009 03:12:28 AM---Hi,


From:

Florent Guillaume <fg@nuxeo.com>

To:

CMIS List <cmis@lists.oasis-open.org>

Date:

07/01/2009 03:12 AM

Subject:

[cmis] discovering containment relationships in queries





Hi,

Suppose I want to find all documents contained in folders marked  
"important". Is there a way to express this in CMIS SQL that I'm  
missing?

At first I thought of doing:
  SELECT doc.* FROM Document doc JOIN Folder fold ON doc.ParentId =  
fold.ObjectId WHERE fold.important = true

However documents don't have a ParentId attribute (and could have  
multiple parents when multi-filing is involved).

I feel that this is an important query use case. Unless I'm missing  
something and people tell me how it can be done, then I'll open a JIRA  
issue for that. At the moment I only see one option, which is to allow  
a single-valued ParentId on documents so that at least the single-
filing case can be dealt-with. I'm not sure it's satisfying though,  
and I'd love to hear others on this.

Florent

--
Florent Guillaume, Head of R&D, Nuxeo
Open Source, Java EE based, Enterprise Content Management (ECM)
http://www.nuxeo.com   http://www.nuxeo.org   +33 1 40 33 79 87


---------------------------------------------------------------------
To unsubscribe from this mail list, you must leave the OASIS TC that
generates this mail.  Follow this link to all your TCs in OASIS at:
https://www.oasis-open.org/apps/org/workgroup/portal/my_workgroups.php 





[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]