-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 
Author Message
 Post subject: Problem with inserting
PostPosted: Fri May 23, 2008 6:25 am 
Newbie

Joined: Fri May 23, 2008 5:36 am
Posts: 1
HI,
I am using mysql, and in my application ,one process are changing the database without using hibernate and insert new row. After that if another application inserting new row in the same table by using hibernate than it gives this error stack....

org.springframework.dao.DataIntegrityViolationException: Hibernate operation: Could not execute JDBC batch update; SQL []; Duplicate key or integrity constraint violation message from server: "Duplicate entry '6928' for key 1"; nested exception is java.sql.BatchUpdateException: Duplicate key or integrity constraint violation message from server: "Duplicate entry '6928' for key 1"
org.springframework.jdbc.support.SQLErrorCodeSQLExceptionTranslator.translate(SQLErrorCodeSQLExceptionTranslator.java:235)
org.springframework.orm.hibernate.HibernateAccessor.convertJdbcAccessException(HibernateAccessor.java:291)
org.springframework.orm.hibernate.HibernateAccessor.convertHibernateAccessException(HibernateAccessor.java:278)
org.springframework.orm.hibernate.HibernateTemplate.execute(HibernateTemplate.java:319)
org.springframework.orm.hibernate.HibernateTemplate.save(HibernateTemplate.java:493)
com.jkt.intranet.dataService.UserDataServiceImpl.updateUser(UserDataServiceImpl.java:367)
com.jkt.intranet.handler.UserHandlerServiceImpl.updateUser(UserHandlerServiceImpl.java:49)
com.jkt.intranet.hrapp.controller.UserController.updateUser(UserController.java:438)
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
java.lang.reflect.Method.invoke(Method.java:585)
org.springframework.web.servlet.mvc.multiaction.MultiActionController.invokeNamedMethod(MultiActionController.java:351)
org.springframework.web.servlet.mvc.multiaction.MultiActionController.handleRequestInternal(MultiActionController.java:305)
org.springframework.web.servlet.mvc.AbstractController.handleRequest(AbstractController.java:128)
org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:44)
org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:684)
org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:625)
org.springframework.web.servlet.FrameworkServlet.serviceWrapper(FrameworkServlet.java:386)
org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:355)
javax.servlet.http.HttpServlet.service(HttpServlet.java:768)
javax.servlet.http.HttpServlet.service(HttpServlet.java:861)


please give me solution for resolve this problem.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.