Re: EO inheritance + Oracle
Re: EO inheritance + Oracle
- Subject: Re: EO inheritance + Oracle
- From: Ken Anderson <email@hidden>
- Date: Tue, 22 Mar 2011 22:18:22 -0400
Not to put a crimp in your model, but is inheritance really necessary here? What actual behavior is different?
One level inheritance is hard to optimize - two levels, doubly so (at least!). If you could share more about what kind of behavior you're looking for from these objects it might be helpful to everyone on the list.
Ken
On Mar 22, 2011, at 7:31 PM, Jon Nolan wrote:
> I have a fairly involved EO inheritance tree that works beautifully in every way but one. Here's a quick example illustrating the structure I'm using:
>
> Human
> North American
> American
> Canadian
> Mexican
> European
> German
> Italian
> Spaniard
> Asian
> Korean
> Laotian
>
> etc. You get the idea.
>
> So if I utilize European.fetchEuropeans(...) a qualifier is generated along the lines of HUMAN_TYPE = German or HUMAN_TYPE = Italian or HUMAN_TYPE = Spaniard. This would be fine except for the Oracle optimizer deciding not to use the HUMAN_TYPE_IDX index. I've tried using hints but (a) it's difficult to get right for a query generated by a ERXBatchingDisplayGroup and (b) the JDBC adaptor disconnects me when I try.
>
> There is another qualifier clause which happens to make it so that, in the European example, all the returned humans will indeed be German, Italian or Spaniard. Is there any way to simply discard the OR'd HUMAN_TYPE qualifier? Any other suggestions? Do I have something wrong in my model in the first place?
>
> Thanks,
> Jon
> _______________________________________________
> 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
_______________________________________________
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