[
https://issues.apache.org/jira/browse/PHOENIX-3440?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Eric Lomore updated PHOENIX-3440:
---------------------------------
Summary: Calcite has specific requirements for date and datetime operations
(was: Calcite doesn't allow numbers to be subtracted from dates)
> Calcite has specific requirements for date and datetime operations
> ------------------------------------------------------------------
>
> Key: PHOENIX-3440
> URL: https://issues.apache.org/jira/browse/PHOENIX-3440
> Project: Phoenix
> Issue Type: Sub-task
> Reporter: Eric Lomore
> Priority: Minor
>
> This popped up just today in the Calcite mailing list, and I noticed some
> test failures in Phoenix due to it.
> testDateSubtractExpressionMetaData1
> testDateSubtractExpressionMetaData1
> testDateSubtractExpressionMetaData1
> These tests fail due to the difference in support.
> Summary of the exception:
> {code}
> Caused by: org.apache.calcite.sql.validate.SqlValidatorException: Cannot
> apply '-' to arguments of type '<DATE> - <DECIMAL(2, 1)>'.
> Supported form(s):
> '<NUMERIC> - <NUMERIC>'
> '<DATETIME_INTERVAL> - <DATETIME_INTERVAL>'
> '<DATETIME> - <DATETIME_INTERVAL>'
> {code}
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)