title: How to map a MySQL JSON column to a Java entity property using JPA and Hibernate
body: <p>I have a MySQL column declared as type <strong>JSON</strong> and I have problems to map it with JPA/Hibernate. I'm using Spring Boot on back-end.</p>
  <p>Here is small part of my code:</p>
  <pre><code>@Entity
  @Table(name = &quot;some_table_name&quot;)
  public class MyCustomEntity implements Serializable {
  
  private static final long serialVersionUID = 1L;
  
  @Id
  @GeneratedValue(strategy = GenerationType.AUTO)
  private Long id;
  
  @Column(name = &quot;json_value&quot;)
  private JSONArray jsonValue;
  </code></pre>
  <p>The program returns me an error and tells me that I can't map the column.</p>
  <p>In mysql table the column is defined as:</p>
  <pre><code>json_value JSON NOT NULL;
  </code></pre>