Top "Sequence-generators" questions

How does the JPA @SequenceGenerator annotation work

I am learning JPA and have confusion in the @SequenceGenerator annotation. To my understanding, it automatically assigns a value to …

java hibernate jpa sequence sequence-generators
Get the next value from SequenceGenerator

I'd like to make use of SequenceGenerator and get the next value from the sequence generator. I want to avoid …

jpa sequence-generators
Replace @SequenceGenerator since its deprecated

I have a problem with @SequenceGenerator: @SequenceGenerator(name="pk_user_id", sequenceName="seq_user_id", allocationSize=1) @GeneratedValue(strategy=GenerationType.SEQUENCE, …

java hibernate sequence-generators
How to implement a custom String sequence identifier generator with Hibernate

I'm using hibernate with spring, h2 and liquibase and I'm trying to make a custom String id generator for my …

java database hibernate identifier sequence-generators
Invalid Object Name for Hibernate Sequence Generator

I am developing an application that accesses a database running SQL Server 2012 through the Hibernate framework. However, I cannot figure …

java database hibernate sql-server-2012 sequence-generators
@SequenceGenerator on class annotated with @MappedSuperclass

I have following structure of my entities: @MappedSuperclass public abstract class BaseEntity { @Id @GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "seqGenerator") private …

java hibernate orm jpa sequence-generators