What mean the "base class" in OOP ?
Can you have an instance of Animal that is not an instance of Dog or an
instance of Cat ?

You still thinking in Tables and not OO... switch your mind ;)

On Wed, Sep 1, 2010 at 12:07 PM, Nick Kirkes <[email protected]> wrote:

> I am currently mapping an object graph using the table-per-subclass
> pattern, specifically <joined-subclass> for concrete implementations
> of an abstract base class.'
>
> For example, let's use:
>
> Dog : Animal
> Cat : Animal
>
> with the following mapping:
>
> <class name="Animal" abstract="true">
>   ...
>   <joined-subclass name="Dog" table="Dogs">...</joined-subclass>
>   <joined-subclass name="Cat" table="Cats">...</joined-subclass>
> </class>
>
> Another developer on our team brought up the issue that a query to
> grab a collection of the base class Animal will instigate a series of
> Left Outer Joins to the various subclasses.  This causes a few
> problems for us that can be worked around but it's a pain.  Is there a
> way to tell NHibernate to not join those classes when we're simply
> asking for the base class?
>
> Thanks in advance,
> Nick
>
> --
> You received this message because you are subscribed to the Google Groups
> "nhusers" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected]<nhusers%[email protected]>
> .
> For more options, visit this group at
> http://groups.google.com/group/nhusers?hl=en.
>
>


-- 
Fabio Maulo

-- 
You received this message because you are subscribed to the Google Groups 
"nhusers" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/nhusers?hl=en.

Reply via email to