Hi, I have the following class inheritance hierarchy:

public class A {}

public class B : A {}

public class C : B {}

public class D : B {}

In the database I have tables A, B, C, D where:

- B has a foreign key relationship to A;
- C and D have foreign key relationships to B;

Both foreign key relationships are established using the PK field of
the tables(PK field type is Decimal).

On top of that, both base classes contain a discriminator column that
indicates the inheritor type.

Question: is this mapping scenario possible in NHibernate(table per
subclass, using the mentioned class inheritance hierarchy)?
If the answer is yes, how should the XML mapping file look like? Are
nested <joined-subclass /> elements allowed/supported?

Thanks in advance for your answer,
Dragos

--~--~---------~--~----~------------~-------~--~----~
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