Re: Disable constraint checking under H2
Re: Disable constraint checking under H2
- Subject: Re: Disable constraint checking under H2
- From: Paul Hoadley <email@hidden>
- Date: Thu, 21 Mar 2013 09:47:11 +1030
On 2013-03-20, at 3:08 PM, Paul Hoadley wrote:
On 21/03/2013, at 1:36 AM, Chuck Hill <email@hidden> wrote:
On 2013-03-20, at 3:12 AM, Paul Hoadley wrote:
On 20/03/2013, at 2:49 PM, Chuck Hill <email@hidden> wrote:
David Avendasora had an improved delegate that I think he mentioned committing to Wonder. Maybe he has not gotten around to it? Logically, you can't have mandatory circular relationships without deferred constraint handling.
Unless I've not looked closely enough at my own model, half of the circle here is optional, which should be alright. (Shouldn't it?) Does the ERXEntityDependencyOrderingDelegate look to see whether the relationships are optional/mandatory and make allowances, or does it just get as far as seeing that there's a cycle?
My version just stopped when it saw a cycle. I think. I have not used it in years.
Yeah, it seems to. I meant "alright" in a more general sense.
I was going to say yes, but realized the answer is No. It is only OK if the optional part is null and that row is inserted first. If it is NOT null, the database will want to verify the validity immediately and it won't be there. The only thing the database knows about the optionality is that null is allowed.
Yeah. I meant "more general sense" in that it's alright to have a model with a cycle where one of the relationships is optional, not in the general sense that _any arbitrary transaction_ will be OK. Going back to the concrete example here, I've got Person.organisation (mandatory—every user is from an organisation) and Organisation.creator (optionally back to Person so that you can indicate which user created a new Organisation object). It does present a bootstrapping problem in that the first Organisation won't have a creator. Is there a better pattern for this kind of thing?
|
_______________________________________________
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