I am trying to use hibernate to accomodate a difficult database design. I have a table (let's call it child) that has:
id parent_id signal_id name signal_name signal_action There is a parent table, and I have a Parent object for that table. To help me display all of this information on the UI, I have created two objects, Child and Signal. For the parent's mapping I have: <bag role="children" table="child" cascade="all"> <key column="id" length="22"/> <one-to-many class="org.example.Child"/> </bag> For the child's mapping I have: <bag role="signals" table="signals" cascade="all"> <key> <column name="id" length="22"/> <column name="signal_id" length="22"/> </key> <one-to-many class="org.example.Signal"/> </bag> When I try to run a test for this DAO, I get: [junit] ERROR [main] DatastoreImpl.store(109) | Could not compile the mapping document [junit] cirrus.hibernate.MappingException: duplicate class mapping: org.example.Signal Is there anyway to do what I'm trying to do? Another option (I suppose) is to query and set these values manually, or loop through the children and break out the signals in a business delegate. Thanks, Matt ------------------------------------------------------- This SF.NET email is sponsored by: FREE SSL Guide from Thawte are you planning your Web Server Security? Click here to get a FREE Thawte SSL guide and find the answers to all your SSL security issues. http://ads.sourceforge.net/cgi-bin/redirect.pl?thaw0026en _______________________________________________ hibernate-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/hibernate-devel