Skip to Main Content

Integration

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Composite Key in Toplink Mapping File - equivalent to Hibernate?

953418Aug 2 2012 — edited Aug 9 2012
Hi,

I have a POJO TestEntity which refers to primary key TestEntityKey. In Hibernate mapping hbm file, we define the entry as:

<composite-id name="id" class="TestEntityKey">
<key-property name ="testEntityCode" column = "TEST_ENT_CODE" type = "string" />
</composite-id>

Please confirm how to create the composite id in Toplink means kindly help that how to map my id to key:

<opm:primary-key>
<opm:attribute-name>id</opm:attribute-name>
<opm:field table="TEST_ENTITY_B" name="TEST_ENT_CODE" xsi:type="opm:column"/>
</opm:primary-key>

Thanks!
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Sep 6 2012
Added on Aug 2 2012
3 comments
428 views