 |
|
 |
 |
|
 |
 |
| Author |
Message |
|
|
Post subject: Could not execute JDBC batch update
Posted: May 15, 2008 - 01:54 PM
|
|
Joined: May 15, 2008
Posts: 1
|
|
Hi ALL,
I run the Qtuickstart Hibernate Introduction tutorial successfully. But when i tried to run again, it started giving this error below.
Please help how to resolve this issue.
log4j:WARN No appenders could be found for logger (org.hibernate.cfg.Environment).
log4j:WARN Please initialize the log4j system properly.
Exception in thread "main" org.hibernate.exception.ConstraintViolationException: Could not execute JDBC batch update
at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:71)
at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:43)
at org.hibernate.jdbc.AbstractBatcher.executeBatch(AbstractBatcher.java:202)
at org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:235)
at org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:139)
at org.hibernate.event.def.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListener.java:297)
at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:27)
at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:985)
at org.hibernate.impl.SessionImpl.managedFlush(SessionImpl.java:333)
at org.hibernate.transaction.JDBCTransaction.commit(JDBCTransaction.java:106)
at com.myeclipse.hibernate.HibernateExample.addUser(HibernateExample.java:41)
at com.myeclipse.hibernate.HibernateExample.main(HibernateExample.java:12)
Caused by: java.sql.BatchUpdateException: Duplicate entry '1' for key 1
at com.mysql.jdbc.ServerPreparedStatement.executeBatch(ServerPreparedStatement.java:657)
at org.hibernate.jdbc.BatchingBatcher.doExecuteBatch(BatchingBatcher.java:58)
at org.hibernate.jdbc.AbstractBatcher.executeBatch(AbstractBatcher.java:195)
... 9 more |
|
|
| |
|
|
|
 |
|
|
Post subject: RE: Could not execute JDBC batch update
Posted: May 15, 2008 - 04:33 PM
|
|
Registered Member


Joined: Apr 18, 2007
Posts: 5662
|
|
Can you go to MyEclipse > Installation Summary > Installation Details and paste the information here for me.
Can you switch to a new workspace and test this project again. Do you still face the same issue ? |
_________________ Nipun
MyEclipse Support
|
| |
|
|
|
 |
|
|
| |
|
|
 |
|
 |
|
|
|
 |