[
https://issues.apache.org/jira/browse/CALCITE-2299?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16512850#comment-16512850
]
Josh Elser commented on CALCITE-2299:
-------------------------------------
Hi [~Sergey Nuyanzin]. We have lots of tests in Avatica which use HSQLDB for
verifying functionality of Avatica functionality outside the context of how
Calcite is using it.
I'm assuming that we already have some basic testing of TimeUnit – it's good
when we can add some kind of test into Avatica itself to try to catch any
issues that Calcite would have otherwise uncovered itself (to avoid the
back-and-forth of calcite finding avatica bugs and forcing multiple new
releases).
So, in short, some kind of test that exercises the new NANOSECONDS enum value
would be appreciated.
> TIMESTAMPADD(SQL_TSI_FRAC_SECOND) should be nanoseconds not microseconds
> ------------------------------------------------------------------------
>
> Key: CALCITE-2299
> URL: https://issues.apache.org/jira/browse/CALCITE-2299
> Project: Calcite
> Issue Type: Bug
> Components: core
> Affects Versions: 1.16.0
> Reporter: James Duong
> Assignee: Julian Hyde
> Priority: Minor
> Fix For: avatica-1.12.0
>
>
> When calling TIMESTAMPADD with the first parameter SQL_TSI_FRAC_SECOND and
> the JDBC escape sequence, this gets interpreted as microseconds when it
> should be interpreted as nanoseconds.
>
> From the ODBC spec on MSDN:
> [https://docs.microsoft.com/en-us/sql/odbc/reference/appendixes/time-date-and-interval-functions?view=sql-server-2017]
> 'where fractional seconds are expressed in billionths of a second.'
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)