当前位置: 代码迷 >> Java Web开发 >> Could not execute JDBC batch update 错误了 如何调试
  详细解决方案

Could not execute JDBC batch update 错误了 如何调试

热度:1015   发布时间:2016-04-16 21:56:43.0
Could not execute JDBC batch update 异常了 怎么调试?
SLF4J: The requested version 1.6 by your slf4j binding is not compatible with [1.5.5, 1.5.6, 1.5.7, 1.5.8]
SLF4J: See http://www.slf4j.org/codes.html#version_mismatch for further details.
SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [jar:file:/F:/data/myjava/%e5%ae%89%e8%a3%85%e5%8c%85%e6%96%87%e4%bb%b6/Hibernate/hibernate%e5%bf%85%e9%a1%bb/slf4j-log4j12-1.6.1.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [jar:file:/D:/Mysoftware/AppData/Local/Genuitec/Common/plugins/com.genuitec.org.hibernate.eclipse_3.2.4.CR1-me201003101716/myeclipse-data/3.3/lib/required/slf4j-log4j12-1.5.8.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
log4j:WARN No appenders could be found for logger (org.hibernate.cfg.Environment).
log4j:WARN Please initialize the log4j system properly.
log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info.
Hibernate: insert into hibernate.LOGIN (password, USERNAME) values (?, ?)
Exception in thread "main" org.hibernate.exception.SQLGrammarException: Could not execute JDBC batch update
at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:90)
at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:66)
at org.hibernate.jdbc.AbstractBatcher.executeBatch(AbstractBatcher.java:275)
at org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:266)
at org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:167)
at org.hibernate.event.def.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListener.java:321)
at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:50)
at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:1028)
at org.hibernate.impl.SessionImpl.managedFlush(SessionImpl.java:366)
at org.hibernate.transaction.JDBCTransaction.commit(JDBCTransaction.java:137)
at com.pb.hibernate.po.LoginDao.save(LoginDao.java:29)
at com.pb.hibernate.test.Test.main(Test.java:18)
Caused by: java.sql.BatchUpdateException: ORA-00942: 表或视图不存在

at oracle.jdbc.driver.DatabaseError.throwBatchUpdateException(DatabaseError.java:343)
at oracle.jdbc.driver.OraclePreparedStatement.executeBatch(OraclePreparedStatement.java:10656)
at org.hibernate.jdbc.BatchingBatcher.doExecuteBatch(BatchingBatcher.java:70)
at org.hibernate.jdbc.AbstractBatcher.executeBatch(AbstractBatcher.java:268)
... 9 more

------解决方案--------------------
insert into hibernate.LOGIN (password, USERNAME) values (?, ?)

表或视图不存在。。。。。。
------解决方案--------------------
可能是表中的列名与数据库中的关键字相同,你查下表
  相关解决方案