67,513
社区成员
发帖
与我相关
我的任务
分享
<hibernate-mapping>
<class name="model.MyClass" table="class" schema="dbo" catalog="student">
<id name="id" type="java.lang.String">
<column name="id" length="32" />
<generator class="uuid.hex" />
</id>
<property name="classNo" type="java.lang.String">
<column name="class_no" length="20" not-null="true" />
</property>
<property name="name" type="java.lang.String">
<column name="class_name" length="20" not-null="true" />
</property>
......
<set name="students" inverse="true" cascade="all">
<key>
<column name="classId" length="32" not-null="true" />
</key>
<one-to-many class="model.Student" />
</set>
</class>
</hibernate-mapping>
<set name="students" inverse="true">
<key>
<column name="classId" length="32" not-null="true" />
</key>
<one-to-many class="model.Student" />
</set>