Hibernate version: 2
Hibernate Synchronizer: 2.1
Eclipse: 3
Name and version of the database you are using: Postgresql 7.3
Hi folks!
I'm facing a problem when I save a hibernate object on postgre using the dao generated by hibernate synchronizer plugin.
I have a table (Table A) on the data base and it's primary key (and also foreign key) is the primary key of another table (Table B).
The hibernate synchronizer created all vos and daos based in the data base. For the described case, it created a vo of Table A that is an specialization of the vo of Table B.
Then, when I save the Table B vo, an row is inserted on table B, and when I save the Table A vo, it inserts an row in table A and another on Table B.
The problem is that I don't want to create another row in Table B, I want to reference the existent one.
Someone knows how to proceed?
Thanks!
|