0 Replies Latest reply on Aug 25, 2006 7:21 PM by F B

    Failure to get next in sequence - EBJ3 CMP entity bean

    F B Newbie

      Could you please look at the below errors and suggest what is going on and how to fix it?

      javax.ejb.EJBException: javax.persistence.PersistenceException: org.hibernate.exception.GenericJDBCException: could not get next sequence value
      at org.jboss.ejb3.tx.Ejb3TxPolicy.handleExceptionInOurTx(Ejb3TxPolicy.java:69)

      The EJB is annotated as:
      ==== class

      ==== pk id annotation
      @GeneratedValue(strategy = GenerationType.SEQUENCE, generator="WW")
      @SequenceGenerator(name="WW", sequenceName="my_seq")
      @Column(name="eqrq_no", nullable=false, insertable=true )

      This is an informix 9.4 DB with the IBM informix drivers and Hibernate Persistence in JBoss 4.04 I have verified that the sequence exists. I have also successfully used iSQL (java sourceforge sql tool) to run the logged hibernate query of:
      select my_seq.nextval from systables where tabid=1