Details
Description
When performing a SqlQuery with a WHERE clause containing an = predicate on a field of type LocalDateTime, the query fails with org.apache.ignite.IgniteCheckedException:Failed to execute SQL query.
This bug occurred in 2.0, the same SqlQuery was working fine on 1.9.
If we dig into the details,the original exception is a ClassCastException on IgniteH2Indexing:3663.
When doing the same kind of query with a WHERE clause on a String type, it works.
You can find a test case showing that here: https://github.com/bgaraude/IgniteTest
I think this is related to IGNITE-4172, but this ticket says that the patch has to be updated once H2 has been updated.
It seems that ignite 2.0 uses an updated version of H2: 1.4.195. This H2 version supports LocalDateTime. At least org.h2.value.DataType.getTypeFromClass returns TimeStamp for the LocalDateTime class. But IgniteH2Indexing$RowDescriptor.wrap() has not been updated accordingly. Hence, the ClassCastException.
Do you know a workaround i can use while this issue is fixed?
Attachments
Attachments
Issue Links
- is related to
-
IGNITE-4172 SQL: Add support for Java 8 Time API classes in date\time functions
- Resolved
- links to