I\'ve got a Category Hibernate model:
@Entity @Table(name = \"category\") public class Category { @Id @GeneratedValue(strategy=GenerationType.AUTO)
Yes, is possible. It should be:
@Enumerated(EnumType.STRING) @Column(name = "category_type") private CategoryType categoryType;
The accepted answer is not sufficient for PostgreSQL. I attach the implementation that worked for me:
https://stackoverflow.com/a/64021041/5279996