[Zope3-Users] Probably the dumbest question I have ever asked: Can an object be in more than one place?

Florent Guillaume fg at nuxeo.com
Mon May 30 09:17:54 EDT 2005

Alec Munro  <alec.munro at eoascientific.com> 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


Florent Guillaume, Nuxeo (Paris, France)   CTO, Director of R&D
+33 1 40 33 71 59   http://nuxeo.com   fg at nuxeo.com

More information about the Zope3-users mailing list