Need help with Hibernate? Read this first:
http://www.hibernate.org/ForumMailingli ... AskForHelp
Hibernate version: 3.05
Mapping documents:
<?xml version="1.0"?>
<!DOCTYPE hibernate-mapping PUBLIC "-//Hibernate/Hibernate Mapping DTD 3.0//EN" "http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd">
<hibernate-mapping>
<class name="com.coginfo.kf.bean.RelazioneParametro" table="KFT_RELAZIONI_PARAMETRI" select-before-update="true">
<meta attribute="class-description">Parametro</meta>
<composite-id name="id" class="com.coginfo.kf.bean.ParametroPk">
<key-many-to-one name="codintpar" class="com.coginfo.kf.bean.Parametro">
<column name="codintrep"/>
<column name="codintpar"/>
</key-many-to-one>
<key-many-to-one name="codintmod" class="com.coginfo.kf.bean.Modalita">
<column name="codintdmn"/>
<column name="codintmod"/>
</key-many-to-one>
</composite-id>
<many-to-one class="com.coginfo.kf.bean.Parametro" name="codintparpdr" not-null="true" lazy="true">
<column name="codintrep"/>
<column name="codintparpdr"/>
</many-to-one>
<property name="camporel" type="string">
<column name="camporel" length="100" sql-type="string" not-null="true"/>
</property>
<property name="logoper" type="string">
<column name="logoper" length="3" sql-type="string" not-null="true"/>
</property>
</class>
</hibernate-mapping>
Full stack trace of any exception that occurs:
org.hibernate.MappingException: Repeated column in mapping for entity: com.coginfo.kf.bean.RelazioneParametro column: codintrep (should be mapped with insert="false" update="false")
Name and version of the database you are using:
Oracle 9i
How is the correct mapping for this table? i've 2 columns that are two many-to-one with the same column
codintparpdr...