MariaDB-java-connector with MySQL 5.7 database not support DATE type

77 Views Asked by At
  • SpringBoot: 2.7.13
  • HikariCP: 4.0.3
  • MariaDB-java-connector: 2.0.1-3.2.0
  • MySQL 5.7 in (wix-embedded-mysql: 4.6.2)

A simple attempt to insert data of the DATE type into a database results in an error.

Caused by: java.sql.SQLException: Could not convert [2018-11-22] to 91
    at org.mariadb.jdbc.internal.util.exceptions.ExceptionMapper.getSqlException(ExceptionMapper.java:192)
    at org.mariadb.jdbc.BasePrepareStatement.setInternalObject(BasePrepareStatement.java:1030)
    at org.mariadb.jdbc.BasePrepareStatement.setObject(BasePrepareStatement.java:833)

I don't know where to find a solution to a problem with HikariCP or MariaDB-java-connector settings. I know that DATE is deprecated, but is there a way to support old databases?

0

There are 0 best solutions below