Ok, I am trying to use the save() or update() method, and this is my problem : I am using a sequence identifier, and on a first database all works fine.
On a second database, I want to replicate all the values, but when I store (with save()) the same object as in my first database, I have this error :
Row was updated or deteled by another transaction (or unsaved-value was incorrect).
In fact, in my first database, the unsaved-value="null" works fine, because the sequence value is correctly generated and assigned to my object. But in the second database, the id is not null ; it has the previously generated value, and THIS IS WHAT I WANT. But I can't store it.
Why is the save() method doesn't correctly store it, and does make an update() instead ?? I tried with unsaved-value="any", but does'nt work.
I am using Hibernate 2.1.3.
Thanks.
|