Search code examples
hibernateusertype

sequence generator and UserType


I have a sequaance generator

<id name="idPersistent" type="objectID" column="aa_id">
         <generator class="sequence">
            <param name="sequence">lab_seq</param>
         </generator>
      </id>  

objectID is my own UserType. I got error

 javax.persistence.PersistenceException: org.hibernate.id.IdentifierGenerationException: this id generator generates long, integer, short or string

What can I do?


Solution

  • try these links, I hope these will help you