hi, I'm using netbeans and hibernate. I have three tables (A table,B table,C table,) and a column in A table is the foreign key of the id column of B and C table.My mapping file of the A table includes
Code:
<many-to-one name="ctable" class="Mapping_classes.Btable" fetch="select">
<column name="g_id" not-null="true" />
</many-to-one>
<many-to-one name="ctable" class="Mapping_classes.Ctable" insert="false" update="false" fetch="select">
<column name="g_id" not-null="true" />
</many-to-one>
netbeans generates this code automatically.But if I want to insert the record using Ctable , it doesn't work.What should i do?