Hello,
i have an error while inserting data. I don't know what causes this error; the INSERTIOn query is correct but the error message reference a relation that does not exist in the database.
the error raises when i execute a session.flush() to persist new instances in the database. The called to session.save() which is lade just before perform well
DBMS: PostgreSQL
Hibernate 3
JDBC 3
Error message:
Hibernate: insert into CLASS_E
(EXIST_EN, EXIST_FR, SOURCE_DOC_OF_DEFINITION, DEFINITION_EN, DEFINITION_FR, NOTE_EN, NOTE_FR, REMARK_EN, REMARK_FR, PREFERRED_NAME_EN, PREFERRED_NAME_FR, SHORT_NAME_EN, SHORT_NAME_FR, ICON, SYNONYMOUS_NAMES_EN_1, SYNONYMOUS_NAMES_EN_2, SYNONYMOUS_NAMES_FR_1, SYNONYMOUS_NAMES_FR_2, DATE_OF_CURRENT_VERSION, DATE_OF_ORIGINAL_DEFINITION, DATE_OF_CURRENT_REVISION, REVISION, ITS_SUPERCLASS, CODE, VERSION, DEFINED_BY, ORIGIN, SIMPLIFIED_DRAWING, CODED_NAME, RTYPE, RID)
values (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, 'ITEM_CLASS', ?)
Hibernate: select nextval ('hibernate_sequence')
org.hibernate.exception.SQLGrammarException: could not insert: [fr.ensma.lisi.flatlib.Item_Class] at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:59) at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:43) at org.hibernate.persister.entity.BasicEntityPersister.insert(BasicEntityPersister.java:1869) at org.hibernate.persister.entity.BasicEntityPersister.insert(BasicEntityPersister.java:2200) at org.hibernate.action.EntityInsertAction.execute(EntityInsertAction.java:46) at org.hibernate.engine.ActionQueue.execute(ActionQueue.java:239) at org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:223) at org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:136) at org.hibernate.event.def.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListener.java:274) at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:27) at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:730) at fr.ensma.lisi.tree.test.main(test.java:93) Caused by: org.postgresql.util.PSQLException: ERROR: relation "class" does not exist at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:1548) at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1316) at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:191) at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:452) at org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:351) at org.postgresql.jdbc2.AbstractJdbc2Statement.executeUpdate(AbstractJdbc2Statement.java:305) at org.hibernate.jdbc.NonBatchingBatcher.addToBatch(NonBatchingBatcher.java:22) at org.hibernate.persister.entity.BasicEntityPersister.insert(BasicEntityPersister.java:1853) ... 9 more [b]Any help would be welcome, thank in advance
|