我现在的是这样的
<?xml version="1.0"?>
<!DOCTYPE hibernate-mapping
PUBLIC "-//Hibernate/Hibernate Mapping DTD//EN"
"http://hibernate.sourceforge.net/hibernate-mapping-2.0.dtd"> <hibernate-mapping>
<class name="com.sunsoft.nspg.hibernate.HibUserRole" table="tb">
<id name="yongh" type="string" unsaved-value="null">
<column name="c1" />
<generator class="assigned"/>
</id>
<property name="gangw" type="string">
<column name="c2" not-null="true"/>
</property>
</class>
</hibernate-mapping> 可是这样的话,c1在数据库里好像不能有相同的。请问怎么修改?
<?xml version="1.0"?>
<!DOCTYPE hibernate-mapping
PUBLIC "-//Hibernate/Hibernate Mapping DTD//EN"
"http://hibernate.sourceforge.net/hibernate-mapping-2.0.dtd"> <hibernate-mapping>
<class name="com.sunsoft.nspg.hibernate.HibUserRole" table="tb">
<id name="yongh" type="string" unsaved-value="null">
<column name="c1" />
<generator class="assigned"/>
</id>
<property name="gangw" type="string">
<column name="c2" not-null="true"/>
</property>
</class>
</hibernate-mapping> 可是这样的话,c1在数据库里好像不能有相同的。请问怎么修改?
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货