I have some checks on my object like @NotNull and some generation like
@Id @GeneratedValue(strategy = AUTO) @Column(name = "ID") private Long id; @Column @GeneratedValue(strategy = GenerationType.AUTO) private Long referenceNumber;
However, when calling EntityManager.merge() these values ββare not generated. Zero fields annotated with @NotNull are transmitted without any complaints. Even id not generated.
Should I somehow switch this generation? How and where?
source share