JPA Version column isn't updating after merge() -


i'm updating entity via entitymanager#merge() new jpa version number jpa isn't being reflected correctly in returned entity.

@stateless @transactionattribute(transactionattributetype.required) public class leadservice {     @persistencecontext(name = "joose")     private entitymanager em;      public lead createorupdatelead(lead lead) {         if (lead.getid() != null) {             em.merge(lead);         } else {             em.persist(lead);         }         return lead;     } 

how should deal this? thanks!


Comments

Popular posts from this blog

javascript - oscilloscope of speaker input stops rendering after a few seconds -

javascript - gulp-nodemon - nodejs restart after file change - Error: listen EADDRINUSE events.js:85 -

Fatal Python error: Py_Initialize: unable to load the file system codec. ImportError: No module named 'encodings' -