Pessoal estou usando um EnumUserType como abaixo:
@Enumerated(EnumType.String)
@Type(type = "com..hibernate.type.EnumUserType", parameters = @Parameter(value = "meu.pacote.EnumTipoPessoa", name = "enumClassName"))
@Column(name = "TP_PESSOA")
private EnumTipoPessoa enumTipoPessoa;
Porém quando coloco a annotação @Type recebo a exception :
Caused by: org.hibernate.MappingException: property mapping has wrong number of columns: meu.modelo.Pagamento.tipoPessoa type: com..hibernate.type.EnumUserType
at org.hibernate.mapping.PersistentClass.validate(PersistentClass.java:459)
at org.hibernate.mapping.RootClass.validate(RootClass.java:215)
at org.hibernate.cfg.Configuration.validate(Configuration.java:1135)
at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1320)
Alguma ideia ?