cayenne-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mike Kienenberger <mkien...@gmail.com>
Subject Re: Vertical inheritance
Date Mon, 31 May 2010 12:17:45 GMT
I guess I'd prefer to at least have the ability to do explicit
mapping, like the modeler currently supports for single-table.

What you're suggesting could work, but we have at least one very deep
and wide inheritance tree in our current app, and the performance hit
of joining more than a hundred tables (so far) unnecessarily would
kill us.


On Mon, May 31, 2010 at 8:00 AM, Andrus Adamchik <andrus@objectstyle.org> wrote:
>
> On May 31, 2010, at 7:48 AM, Mike Kienenberger wrote:
>
>> I didn't completely understand the question, so I'm not sure if this
>> answers it.
>
> I guess the question was whether we want this in Cayenne mapping in some
> form:
>
>   @Inheritance(strategy = InheritanceType.JOINED)
>
> or guess the strategy from other mapping clues (the later is our current
> approach). It was more of a discussion item on what are the benefits of
> either approach.
>
>> @DiscriminatorColumn(name="object_type")
>
> Actually my plan is to use OUTER joins in Cayenne SELECT queries, so entity
> type will be determined from the presence of the non-null joined ID column
> in the result set and explicit discriminator ("entity qualifier expression"
> in Cayenne terms) won't be needed.
>
> Andrus
>
>

Mime
View raw message