Skip to Main Content

Oracle Database Discussions

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Tableowner can't insert into table (ORA-00942)

960412Sep 6 2012 — edited Sep 6 2012
Hello everyone

I experience a strange behaviour on some of our development schemas where tableowners can't insert into their own tables. It's a Java 1.5 WebApplication using Hibernate that is running in a tomcat.

The only thing inside the hibernate transaction is the insert which throws the ORA-00942 on commit. I used jdbclogger to get the statement with the values sent to the db and the statement inserts without error in SQL Developer.

I found a reference to a similar behaviour in [ this thread|https://forums.oracle.com/forums/thread.jspa?threadID=2426167] But without the description of Bug 1287914.1. I can't tell for sure if it is the same.


Does anybody has an idea what ishappenign here?

best regards
Daniel Brachmann

JavaCode:
BaseService service = null;
try {
service = new BaseService(eventLogLine.getChangePerson(), m);
service.insert(eventLogLine);
service.commit();
} finally {
BaseService.close(service);
}

Stacktrace:

2012-09-06 13:41:52,108 WARN JDBCExceptionReporter [71] - SQL Error: 942, SQLState: 42000
2012-09-06 13:41:52,108 ERROR JDBCExceptionReporter [72] - ORA-00942: Tabelle oder View nicht vorhanden
2012-09-06 13:41:52,109 ERROR AbstractFlushingEventListener [300] - Could not synchronize database state with session
org.hibernate.exception.SQLGrammarException: Could not execute JDBC batch update
at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:67)
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 de.innuce.common.service.BaseService.commit(BaseService.java:986)
at de.innuce.common.log4j.DatabaseAuthenticationAppender.save(DatabaseAuthenticationAppender.java:97)
at de.innuce.common.log4j.DatabaseAuthenticationAppender.append(DatabaseAuthenticationAppender.java:74)
at org.apache.log4j.AppenderSkeleton.doAppend(AppenderSkeleton.java:251)
at org.apache.log4j.helpers.AppenderAttachableImpl.appendLoopOnAppenders(AppenderAttachableImpl.java:66)
at org.apache.log4j.AsyncAppender$Dispatcher.run(AsyncAppender.java:586)
at java.lang.Thread.run(Thread.java:595)
Caused by: java.sql.BatchUpdateException: ORA-00942: Tabelle oder View nicht vorhanden

at oracle.jdbc.driver.OraclePreparedStatement.executeBatch(OraclePreparedStatement.java:10055)
at oracle.jdbc.driver.OracleStatementWrapper.executeBatch(OracleStatementWrapper.java:213)
at net.sourceforge.jdbclogger.core.StatementWrapper.executeBatch(StatementWrapper.java:144)
at net.sourceforge.jdbclogger.core.PreparedStatementWrapper.executeBatch(PreparedStatementWrapper.java:187)
at com.mchange.v2.c3p0.impl.NewProxyPreparedStatement.executeBatch(NewProxyPreparedStatement.java:1723)
at org.hibernate.jdbc.BatchingBatcher.doExecuteBatch(BatchingBatcher.java:58)
at org.hibernate.jdbc.AbstractBatcher.executeBatch(AbstractBatcher.java:195)
... 14 more
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Oct 4 2012
Added on Sep 6 2012
15 comments
6,097 views