Jeremy Stein - Brain
« JNDI Tomcat 5 | Acegi Hibernate LazyInitializationException » |
Row was updated or deleted by another transaction
org.hibernate.StaleObjectStateException: Row was updated or deleted by another transaction (or unsaved-value mapping was incorrect)
I got this message when I was simply creating a new object. The problem was that my version column was not recognized as being new. I had to either change it from long to java.lang.Long (so that it would be null when new), or add unsaved-value=”negative” to the mapping declaration and initialize the value to -1.
No Comments
Be the first to comment!
« JNDI Tomcat 5 | Acegi Hibernate LazyInitializationException » |
Leave a Reply