Alec Munro <[EMAIL PROTECTED]> wrote: > Hi List, > > I think I've been working with Zope2 in a TTW manner for too long. > > Is it possible to reference an object in two places? I am guilty of > thinking that not using a relational database would make it difficult > to reference and object in more than one place. > In my case, I have a collection of medications, and a collection of patients. > I would like to have the medications a patient is taking as a property > of that patient. > I was originally thinking that I would have to make a copy of the > given medication and store that copy as a property of the patient. > However, it really seems as if it would be sufficient to simply assign > the medication directly as a property of the patient. For some reason > this concept seemed impossible to me a couple days ago, but seems like > the obvious solution now.
Yes, you can do that. There are no restriction to storing objects in multiple places, this is python. The only restriction is with respect to the Container interfaces, an object can only have one __parent__. But if you just store objects by other methods than Containers, there are no limits. Florent -- Florent Guillaume, Nuxeo (Paris, France) CTO, Director of R&D +33 1 40 33 71 59 http://nuxeo.com [EMAIL PROTECTED] _______________________________________________ Zope3-users mailing list Zope3firstname.lastname@example.org http://mail.zope.org/mailman/listinfo/zope3-users