I have a composite-id element in a child object: <composite-id class="com.comcast.cable.dmc.itd.cct.persistence.CCRRecordPK" unsaved-value="any"> <key-property column="CCR_ID" length="22" name="ccrId" type="long"/> <key-property column="RECORD_NUM" length="22" name="recordNum" type="long"/> </composite-id>
The CCRRecordPK class has two properties, ccrId and recordNum, both are java.lang.Long. In it's parent, I want to correctly map to this child, but I can't seem to figure out the mapping - and couldn't find any examples. I have this: <bag role="mpsList" table="CMCF_MPS" cascade="all" order-by="record_num"> <key column="CCR_ID" length="22"/> <one-to-many class="com.comcast.cable.dmc.itd.cct.persistence.CMCFMps"/> </bag> but it doesn't work: [junit] Caused by: java.lang.ClassCastException [junit] at cirrus.hibernate.loader.Loader.getKeyFromResultSet(Loader.java:238) [junit] at cirrus.hibernate.loader.Loader.doFind(Loader.java:155) [junit] at cirrus.hibernate.loader.Loader.loadCollection(Loader.java:503) [junit] at cirrus.hibernate.loader.OneToManyLoader.initialize(OneToManyLoader.java:81) Any help is greatly appreciated. ------------------------------------------------------- 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