Hi All,
We have two related objects: Employee (has a) Position.
Position has a field, brandId, that we want included in Employee as well, but I am not sure how to do it, and I am not sure what to look for in the Hibernate documentation.
Hibernate version: 2.1.5
Name and version of the database you are using: DB2 UDB v8.2
Code:
<?xml version="1.0"?>
<!DOCTYPE hibernate-mapping
PUBLIC "-//Hibernate/Hibernate Mapping DTD//EN"
"http://hibernate.sourceforge.net/hibernate-mapping-2.0.dtd">
<hibernate-mapping>
<class name="com.cml.hr.portal.employ.business.people.Employee"
optimistic-lock="version"
table="EPT614">
<id type="string" name="id" length="61">
<generator class="assigned"/>
</id>
<property name="name"/>
<many-to-one name="position" foreign-key="EPR614A"/>
<!-- ????-->
<property name="brandId" VALUE="position.brandId"/>
</class>
</hibernate-mapping>
Any assistance would be appreciated!
Rob
:)