Hi all,
I have an object with a version attribute, i have also a version tag in my hbm mapping file. If i run the code:
Code:
AObj someObj= // already populated before;
AObj merged= (AObj) session.merge(someObj);
session.saveOrUpdate(merged);
session.flush();
The version column is updated correctly in my table, but not in my "someObj" object, so i'm forced to add this line in order to get my object updated.
Code:
BeanUtils.copyProperties(merged, someObj);
Is this the right solution for this issue?
Thanks in advance.