I have a mapping with the following child (bag) declared in the hbm.xml file:
<bag role="irtList" table="CMCF_IRT" cascade="all" order-by="record_num"> <key column="CCR_ID" length="22"/> <one-to-many class="com.comcast.cable.dmc.itd.cct.persistence.CMCFIrt"/> </bag> This works fine, but the true primary key is two columns: <bag role="irtList" table="CMCF_IRT" cascade="all" order-by="record_num"> <key> <column name="CCR_ID" length="22"/> <column name="RECORD_NUM" length="22"/> </key> <one-to-many class="com.comcast.cable.dmc.itd.cct.persistence.CMCFIrt"/> </bag> But when I try with the 2nd (I'm sure my syntax is wrong), I get the following error: [junit] cirrus.hibernate.MappingException: Foreign key must have same number of columns as refer nced primary key [junit] com.comcast.cable.dmc.itd.cct.persistence.DAOException: cirrus.hibernate.MappingExceptio : Foreign key must have same number of columns as referenced primary key Thanks for any help you can offer. 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