【发布时间】:2017-04-25 06:44:19
【问题描述】:
`
<hibernate-mapping>
<class name="beans.EmployeeBean" table="employeedetails" schema="Employee">
<id name="empId" column="empid"/>
<id name="employeeusername" column="username"/>
<property name="firstname" column="firstname"/>
<property name="designation" column="designation"/>
<property name="email" column="email"/>
<property name="role" column="role"/>
</class>
</hibernate-mapping>
在这段代码中,当我输入第二个 id 用户名时出现错误,并且在我的数据库中也在 1 个表中,我将 2 列作为主键。
【问题讨论】:
-
你尝试过这里建议的答案吗:stackoverflow.com/questions/27642101/…
标签: hibernate