Hallo 

I have solved the problem by this workaround
http://www.mail-archive.com/[email protected]/msg06973.html

Hope it helps.

Per

-----Original Message-----
From: Krzysztof Swietlinski [mailto:[EMAIL PROTECTED]]
Sent: 23. maj 2002 10:54
To: [EMAIL PROTECTED]
Subject: [castor-dev] Collection of different types


Can I have a collection of different types? My
situation is as follow: an Order has many LineItems,
however LineItem class is abstract with 2 different
subclasses: ConcreteLineItem1, ConcreteLineItem2

I have tables for each: Order, LineItem,
ConcreteLineItem1 and ConcreteLineItem2

Originally my Order mapping looked like this:
<field name="lineItems" type="LineItem"
collection="collection">
       <sql many-key="order"/>
 </field>

however this tries to instantiate LineItem object
which is abstract :(

Is there an easy way to load lineItems collection from
both concrete tables?

Thanks,
Krzysztof

__________________________________________________
Do You Yahoo!?
LAUNCH - Your Yahoo! Music Experience
http://launch.yahoo.com

----------------------------------------------------------- 
If you wish to unsubscribe from this mailing, send mail to
[EMAIL PROTECTED] with a subject of:
        unsubscribe castor-dev

----------------------------------------------------------- 
If you wish to unsubscribe from this mailing, send mail to
[EMAIL PROTECTED] with a subject of:
        unsubscribe castor-dev

Reply via email to