how to store PostgreSQL jsonb using SpringBoot + JPA?
I'm working on a migration software that will consume unknown data from REST services. I already think about use MongoDB but I decide to not use it and use PostgreSQL. After read this I'm trying to implement it in my SpringBoot app using Spring JPA but I don't know to map jsonb in my entity. Tried this but understood nothing! Here is where I am: @Repository @Transactional public interface DnitRepository extends JpaRepository<Dnit, Long> { @Query(value = "insert into dnit(id,data) VALUES (:id,:data)", nativeQuery = true) void insertdata( @Param("id")Integer id,@Param("data") String data ); }