Sun Java System Application Server Enterprise Edition 8.2 Developer's Guide

cmr-field-mapping

A container-managed relationship field has a name and one or more column pairs that define the relationship. There is one cmr-field-mapping element for each cmr-field element in the ejb-jar.xml file. A relationship can also participate in a fetch group.

Superelements

entity-mapping (sun-cmp-mappings.xml)

Subelements

The following table describes subelements for the cmr-field-mapping element.

Table A–30 cmr-field-mapping Subelements

Element  

Required  

Description  

cmr-field-name

only one 

Specifies the Java identifier of a field. Must match the value of the cmr-field-name subelement of the cmr-field that is being mapped.

column-pair

one or more 

Specifies the pair of columns that determine the relationship between two database tables. 

fetched-with

zero or one 

Specifies the fetch group for this CMR field’s relationship.