Re: EOF inserts PK automatically
Re: EOF inserts PK automatically
- Subject: Re: EOF inserts PK automatically
- From: Anjo Krank <email@hidden>
- Date: Mon, 22 Nov 2004 11:52:02 +0100
Am 22.11.2004 um 11:36 schrieb Sako!:
i still dont see any reason WHY should i do not do this?
the disadvantage is, the DB will update the same col. twice :)
I'm not so sure: EOF might not use the same transaction for getting the
key number as you are - so then a likely scenario is
- EOF gets a PK (30) from EO_PK_TABLE or whatever, which is currently
the highest PK (29) + 1
- other code directly inserts an object, commits, the highest PK is now
30
- you insert: bang, tried to insert duplicate PK
So the only real way to do this is to use the *same* means for
generation for all or at least disable concurrent access.
Cheers, Anjo
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden