Hi again,

According to the docs, the auto-xy options should be left at their
defaults for ODMG to work correctly. I'm not sure how this really
affects things, but obviously something goes wrong with
auto-update=true.

The remaining problem is probably solved by doing both a
zz.addOption(o1) *and* o1.setZertifikat(zz) (or similar).

I guess it is arguable whether this should be necessary, but in my
view this makes sense, because otherwise the objects to store are
basically inconsistent, and the ODMG layer has to guess what to do. It
may seem obvious what to do when first inserting the objects, but
later if you say o1.setZertifkat(null) without zz.removeOption(o1),
the objects are in the same state, and it is not at all clear what the
intended behavior should be.

In my object models I usually include o1.setZertifikat(this) in the
method zz.addOption().

Cheers,
Gerhard


On Thu, 30 Oct 2003 14:14:58 +0100, Gunnar Hilling
<[EMAIL PROTECTED]> wrote:

>On Thu, 30 Oct 2003 08:58:33 +0100, Gerhard Grosse wrote:
>
>Hello Gerhard,
>
>Thanks for your Proposal. I think the problem is somewhere where you
>pointed out.
>But it't not exactly what you proposed. I think there is a problem whith
>"auto-update" and "auto-retrieve"- Options. If "Option" is auto-updated
>from "Zertifikatschein" AND from "Zertifikat" there is an error with a
>duplicated primary key.
>Seems the same options is tried to be written twice. If I remove the
>"auto-update" from "Zertifikat" this is OK, but the foreign key for
>Zertifikat will not be written to Option...
>So what should I do??
>
>Regards,
>
>-Gunnar



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to