Andrus,
> Ordering of operations has been around for a while and proved to be
> very stable. I am fairly sure there is something with the mapping of
> the relationship (DB constraints and Cayenne mapping do not match). Is
> this the case described here:
> http://objectstyle.org/jira/secure/ViewIssue.jspa?key=CAY-41
No, it's different. The Member table has a FK to BillAccount, but the
BillAccount does not directly refer to the member at all.
There is one more class in the mix: Address. Each address has a
nullable FK back to the member. Maybe that's causing the problem? I
need to write a simple test case to see what's going on.
I think I could force the BillAccount to be written first by calling
context.commitChanges() after creating the bill account but before
creating the member. (a) I'm not yet sure I can do that and (b) there
goes any hope of rolling back if anything goes wrong.
In the mean time, I may have to remove all FK support from my database
entirely. I'm too close to my delivery date to spend much time with
this, I'm afraid.
Jim
-- Jim Menard, jim..o.com, http://www.io.com/~jimm/ "The American legal system is, of course, just the British kernel with a shorter uptime and a few clumsy security patches slapped in." -- www.ntk.net
This archive was generated by hypermail 2.0.0 : Thu Jan 29 2004 - 11:41:22 EST