Skip to main content
The 2024 Developer Survey results are live! See the results
added 48 characters in body
Source Link
Vlad Mihalcea
  • 150.7k
  • 84
  • 586
  • 960

I had the same issue as you, and was stuck on it full day, really frustrating. But now I have fixed it. My fixes are:

  1. Match the versions. I was using Hibernate 5.1 and vladmihalcea hibernate-types-55hypersistence-utils-hibernate-55. However, according to the README in the repo (https://github.com/vladmihalcea/hibernate-types)README in the repo, I should use comio.vladmihalceahypersistence: hibernatehypersistence-typesutils-hibernate-5: 2.203.0.1 with Hibernate 5.1. However, in your case, I would try to unify the Hibernate versions first, and then choose the matching version for hibernatehypersistence-typesutils.
  2. Use the correct annotation. In my Entity, I was annotating the field @Type(type = "jsonb"). After changing it to @Type(type = "json"). It started to work.

Hopefully, this can help you.

I had the same issue as you, and was stuck on it full day, really frustrating. But now I have fixed it. My fixes are:

  1. Match the versions. I was using Hibernate 5.1 and vladmihalcea hibernate-types-55. However, according to the README in the repo (https://github.com/vladmihalcea/hibernate-types), I should use com.vladmihalcea: hibernate-types-5: 2.20.0 with Hibernate 5.1. However, in your case, I would try to unify the Hibernate versions first, and then choose the matching version for hibernate-types.
  2. Use the correct annotation. In my Entity, I was annotating the field @Type(type = "jsonb"). After changing it to @Type(type = "json"). It started to work.

Hopefully this can help you.

I had the same issue as you, and was stuck on it full day, really frustrating. But now I have fixed it. My fixes are:

  1. Match the versions. I was using Hibernate 5.1 and hypersistence-utils-hibernate-55. However, according to the README in the repo, I should use io.hypersistence: hypersistence-utils-hibernate-5: 3.0.1 with Hibernate 5.1. However, in your case, I would try to unify the Hibernate versions first, and then choose the matching version for hypersistence-utils.
  2. Use the correct annotation. In my Entity, I was annotating the field @Type(type = "jsonb"). After changing it to @Type(type = "json"). It started to work.

Hopefully, this can help you.

Source Link
huan
  • 21
  • 1

I had the same issue as you, and was stuck on it full day, really frustrating. But now I have fixed it. My fixes are:

  1. Match the versions. I was using Hibernate 5.1 and vladmihalcea hibernate-types-55. However, according to the README in the repo (https://github.com/vladmihalcea/hibernate-types), I should use com.vladmihalcea: hibernate-types-5: 2.20.0 with Hibernate 5.1. However, in your case, I would try to unify the Hibernate versions first, and then choose the matching version for hibernate-types.
  2. Use the correct annotation. In my Entity, I was annotating the field @Type(type = "jsonb"). After changing it to @Type(type = "json"). It started to work.

Hopefully this can help you.