Details
-
Bug
-
Status: Open (View Workflow)
-
Minor
-
Resolution: Unresolved
-
2.2.5
-
None
-
None
Description
First, I create a simple table with a DATE column:
create table t (a date);
insert into t (a) values(300); – bad date here
Then I select from it without any type:
select * from t; – in the command line returns 2000-02-29
But if I use ResultSet.getObject(index, class) JDBC, I get:
LocalDate v = rs.getObject(1, LocalDate.class);
java.sql.SQLException: 2000-03-00 cannot be parse as LocalDate (format is "yyyy-MM-dd" for data type "DATE")
at org.mariadb.jdbc.internal.com.read.resultset.rowprotocol.TextRowProtocol.getInternalLocalDate(TextRowProtocol.java:947)
at org.mariadb.jdbc.internal.com.read.resultset.SelectResultSet.getObject(SelectResultSet.java:1340)}}