hi. yes, sure i did. only difference is the @column annotation:
Code:
@Version
@Column(name="OPTLOCK")
public Integer getVersion() {
return this.version;
}
public void setVersion(Integer version) {
this.version = version;
}
hibernate does increment the value on every update, it just doesnt throw an exception, but seams to ignore the update. probably there is a misunderstanding of the optimistic locking mechanism on my side. maybe someone could reply to my earlier question:
does hibernate check for optimistic locking if i dont close the current session between loading and updating the datarow?