ignite-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Igor Sapego <isap...@gridgain.com>
Subject Re: Timestamp and Time types in SQL queries
Date Thu, 16 Mar 2017 15:36:27 GMT
Well, I wrote tests and they are failing. So what is the solution here?
Can it be fixed somewhere in Ignite or is it not possible without edits in
H2?

Best Regards,
Igor

On Thu, Mar 16, 2017 at 6:31 PM, Sergi Vladykin <sergi.vladykin@gmail.com>
wrote:

> This happens because H2 does not work with these classes directly and we do
> some conversions to SQL types, then from H2 JDBC API we get what H2 gives
> us. The resulting types can be different. I guess you have to just write
> tests for all these types and cover all these cases in C++ code.
>
> Sergi
>
> 2017-03-16 18:14 GMT+03:00 Igor Sapego <isapego@apache.org>:
>
> > Hi guys,
> >
> > I'm working on java.sql.Time type support for ODBC [1], and I'm facing
> > following behaviour:
> >
> > Lets suppose I perform an SQL query from C++ on field of java.sql.Time
> > type:
> >
> > SELECT dateField from SomeType
> >
> > Nothing special here. The problem is in C++ I get value of type Date
> > instead of Time. The similar behaviour can be observed for the
> > java.sql.Date type (returned as Timestamp in binary protocol). I have not
> > investigated issue yet but I suppose it has to do something with
> > java.sql.Time and java.sql.Timestamp both being a subclasses of the
> > java.util.Date.
> >
> > So the question is, is this an expected behaviour or is it a bug?
> >
> > [1] - https://issues.apache.org/jira/browse/IGNITE-4691
> >
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message