my Problem is that I cannot place a subclass into a joined-subclass.
Any adea How I can solve my problem.
I've read about <any>, but cannot figure out if it can help, and how.
thanks
Code:
class A
{
String id;
}
class AA extends A
{
}
class BA extends A
{
}
abstract class CA extends A
{
}
class ACA extends CA
{
}
class BCA extends CA
{
}
class A is in table T_A
+-------------------------------
| TABLE T_A
| -------------------------------
| ID_A NUMBER(28) not null
+-------------------------------
calss AA is in table T_AA
+-------------------------------
| TABLE T_AA
| -------------------------------
| ID_AA NUMBER(28) not null
+-------------------------------
class BA is in table T_BA
+-------------------------------
| TABLE T_BA
| -------------------------------
| ID_BA NUMBER(28) not null
+-------------------------------
class CA, ACA, BCA are in table T_CA
... where table T_CA contains a column for discriminator TYPE_CA, so I can hava a ACA or a BCA
+-------------------------------
| TABLE T_CA
| -------------------------------
| ID_CA NUMBER(28) not null
| TYPE_CA varchar(5) notnull
+-------------------------------
I WANT ( skipped unnessary info )
-------
<class name="A" table="T_A">
<ID name="id" column="ID_A" />
...
<joined-subclass name="AA" table="T_AA">
...
</joined-subclass
<joined-subclass name="BA" table="T_BA">
...
</joined-subclass
<joined-subclass name="CA" table="T_CA">
...
<discriminator column="TYPE_CA">
<subclass name="ACA" discriminator-value="ACA" >
...
</subclass>
<subclass name="BCA" discriminator-value="BCA" >
...
</subclass>
</joined-subclass