Re: sequential numbering across more instances
Re: sequential numbering across more instances
- Subject: Re: sequential numbering across more instances
- From: Ondřej Čada <email@hidden>
- Date: Sat, 16 Aug 2008 03:03:43 +0200
Alan,
On Aug 16, 2008, at 2:47 AM, Alan Ward wrote:
That would do it, yes. Have EOF insert the record with a null value
in the column
Actually, rather with some specific non-null placeholder, for there
are records which have valid NULL there.
and use a trigger (after insert) to assign the value from a sequence.
... if and only if there is the placeholder.
Be aware though that you should not lock on that column or else
you'll run into optimistic locking failures if you subsequently
update any other column before refetching the (now modified) EO.
Yup, that Chuck has pointed out to me at the very beginning, when
triggers were mentioned the first time.
Looks like the best solution; the only drawback in my case is that
FrontBase needs to be launched with a special option to support
triggers: I can very much see the "why does it not work" problems at
client's, caused by wrong setup here :)
Still, all the other solutions look more complex/more error-prone.
Best,
---
Ondra Čada
OCSoftware: email@hidden http://www.ocs.cz
private email@hidden http://www.ocs.cz/oc
_______________________________________________
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