5 Replies Latest reply on May 30, 2009 2:01 PM by Heiko Braun

    Unexpected token: LAST_INSERT_ID in statement [select last_i

    Heiko Braun Master

      The deploy cmd currently fails with the following exception on HSQLDB & AS 5.1.0

      17:29:57,521 WARN [JDBCExceptionReporter] SQL Error: -11, SQLState: 37000
      17:29:57,521 ERROR [JDBCExceptionReporter] Unexpected token: LAST_INSERT_ID in statement [select last_insert_id()]
      17:29:57,521 INFO [DefaultCommandService] exception while executing command org.jbpm.pvm.internal.cmd.DeployCmd@33ab1d
      org.hibernate.exception.SQLGrammarException: could not retrieve generated id after insert: [org.jbpm.pvm.internal.repository.DeploymentImpl]
      at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:90)
      at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:66)
      at org.hibernate.id.insert.AbstractSelectingDelegate.performInsert(AbstractSelectingDelegate.java:93)
      at org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:2186)
      at org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:2666)
      at org.hibernate.action.EntityIdentityInsertAction.execute(EntityIdentityInsertAction.java:71)
      at org.hibernate.engine.ActionQueue.execute(ActionQueue.java:279)
      at org.hibernate.event.def.AbstractSaveEventListener.performSaveOrReplicate(AbstractSaveEventListener.java:321)
      at org.hibernate.event.def.AbstractSaveEventListener.performSave(AbstractSaveEventListener.java:204)
      at org.hibernate.event.def.AbstractSaveEventListener.saveWithGeneratedId(AbstractSaveEventListener.java:130)
      at org.hibernate.event.def.DefaultSaveOrUpdateEventListener.saveWithGeneratedOrRequestedId(DefaultSaveOrUpdateEventListener.java:210)
      at org.hibernate.event.def.DefaultSaveEventListener.saveWithGeneratedOrRequestedId(DefaultSaveEventListener.java:56)
      at org.hibernate.event.def.DefaultSaveOrUpdateEventListener.entityIsTransient(DefaultSaveOrUpdateEventListener.java:195)
      at org.hibernate.event.def.DefaultSaveEventListener.performSaveOrUpdate(DefaultSaveEventListener.java:50)
      at org.hibernate.event.def.DefaultSaveOrUpdateEventListener.onSaveOrUpdate(DefaultSaveOrUpdateEventListener.java:93)
      at org.hibernate.impl.SessionImpl.fireSave(SessionImpl.java:562)
      at org.hibernate.impl.SessionImpl.save(SessionImpl.java:550)
      at org.hibernate.impl.SessionImpl.save(SessionImpl.java:546)
      at org.jbpm.pvm.internal.repository.RepositorySessionImpl.deploy(RepositorySessionImpl.java:55)
      at org.jbpm.pvm.internal.cmd.DeployCmd.execute(DeployCmd.java:47)