You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@calcite.apache.org by "Julian Hyde (JIRA)" <ji...@apache.org> on 2017/01/26 23:34:24 UTC
[jira] [Comment Edited] (CALCITE-1606) Add missing support for
datetime JDBC functions
[ https://issues.apache.org/jira/browse/CALCITE-1606?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15840660#comment-15840660 ]
Julian Hyde edited comment on CALCITE-1606 at 1/26/17 11:33 PM:
----------------------------------------------------------------
Nice work.
Because it is not standard SQL, I'm not sure that {{YEAR(dt)}} should be available in the default dialect. (I do think that {{EXTRACT(YEAR FROM dt))}} and \{\{ {{fn YEAR(dt)}} \}\} should be available in all dialects.) Maybe they can move into a table analogous to OracleSqlOperatorTable. What do you think?
In the doc, the highest value for MINUTE and SECOND is 59, I believe.
As in your previous patch, I think that {{rewriteCall}} doesn't add much and can go.
was (Author: julianhyde):
Nice work.
Because it is not standard SQL, I'm not sure that {{YEAR(dt)}} should be available in the default dialect. (I do think that {{EXTRACT(YEAR FROM dt))}} and {{\{\{ fn YEAR(dt)\}\}}} should be available in all dialects.) Maybe they can move into a table analogous to OracleSqlOperatorTable. What do you think?
In the doc, the highest value for MINUTE and SECOND is 59, I believe.
As in your previous patch, I think that {{rewriteCall}} doesn't add much and can go.
> Add missing support for datetime JDBC functions
> -----------------------------------------------
>
> Key: CALCITE-1606
> URL: https://issues.apache.org/jira/browse/CALCITE-1606
> Project: Calcite
> Issue Type: Improvement
> Components: core
> Reporter: Laurent Goujon
> Assignee: Julian Hyde
> Priority: Minor
>
> Calcite advertises support for all datetime functions but implementations are missing for some of them.
> Since Calcite already supports EXTRACT(timeUnit FROM datetime), support could be added for the following functions: YEAR, MONTH, WEEK, DAYOFYEAR, DAYOFMONTH, DAYOFWEEK, HOUR, MINUTE, SECOND.
> Some concrete implementation (like WEEK) would be missing, but if RexImpTable is updated to support it, then it would be fully wired.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)