本身多主键配置
<composite-id>
<key-property name="xkkh" type="java.lang.String">
<column name="xkkh" length="20" not-null="true"/>
</key-property>
<key-property name="skdx" type="java.lang.String">
<column name="skdx" length="20" not-null="true"/>
</key-property>
</composite-id>
多主键many-to-many映射配置:多主键用<key>标签中的<columu>标签表示
<set name="teacherBeans" table="KK_JS_VIEW" schema="ZFXFZB">
<key>
<column name="xkkh"/>
<column name="skdx"/>
</key>
<many-to-many class = "TeacherBean" column="jszgh"/>
</set>
many-to-one
<many-to-one name="kkBean" class="edu.dzu.sjjw.entity.KkBean"
insert="false" update="false">
<column name="xkkh"/>
<column name="skdx"/>
</many-to-one>