I'm encountering the following exception with hibernate:
java.sql.SQLException: Incorrect string value: '\xD4BRh\xF09...' for column 'id' at row 1
I have a Java/JPA/Hibernate/MySQL based app. I want to use UUIDs for object identity. This is when trying to save a uuid in a mysql database. The database is configured to use utf8mb4 (and utf8mb4_general_ci collation). MySQL version 8.0.22
With the following column definition
@Id
@GeneratedValue(generator = "UUID")
@GenericGenerator(
name = "UUID",
strategy = "org.hibernate.id.UUIDGenerator"
)
@Column(name = "id", updatable = false, nullable = false)
private UUID id;
Is there something I'm missing? Thank you!