Hibernate mapping between PostgreSQL enum and Java enum
You can simply get these types via Maven Central using the Hypersistence Util dependency: <dependency> <groupId>io.hypersistence</groupId> <artifactId>hypersistence-utils-hibernate-55</artifactId> <version>${hibernate-types.version}</version> </dependency> If you easily map Java Enum to a PostgreSQL Enum column type using the following custom Type: public class PostgreSQLEnumType extends org.hibernate.type.EnumType { public void nullSafeSet( PreparedStatement st, Object value, int index, SharedSessionContractImplementor session) throws HibernateException, … Read more