[teiid-issues] [JBoss JIRA] (TEIID-4224) HANA translator : incorrect pushdown of DAYOFWEEK function
RH Bugzilla Integration (JIRA)
issues at jboss.org
Fri Jun 3 17:07:00 EDT 2016
[ https://issues.jboss.org/browse/TEIID-4224?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13247905#comment-13247905 ]
RH Bugzilla Integration commented on TEIID-4224:
------------------------------------------------
Van Halbert <vhalbert at redhat.com> changed the Status of [bug 1339611|https://bugzilla.redhat.com/show_bug.cgi?id=1339611] from MODIFIED to ON_QA
> HANA translator : incorrect pushdown of DAYOFWEEK function
> ----------------------------------------------------------
>
> Key: TEIID-4224
> URL: https://issues.jboss.org/browse/TEIID-4224
> Project: Teiid
> Issue Type: Bug
> Components: Misc. Connectors
> Affects Versions: 8.12.5
> Reporter: Jan Stastny
> Assignee: Steven Hawkins
> Fix For: 9.0, 8.12.5, 8.13.5
>
>
> Teiid's DAYOFWEEK function:
> {code:plain}
> DAYOFWEEK(x) Return day of week (Sunday=1, Saturday=7)
> {code}
> is pushed down as:
> {code:plain}
> dayname(g_0."DATEVALUE")
> {code}
> but this function returns string representation of the day.
> More appropriate would be to push DAYOFWEEK as WEEKDAY function, but the returned value has to be adapted to Teiid's representation (Sunday=1 and Saturday=7, vs. HANA's Monday=0,Sunday=6). So the solution would be to push:
> {code:sql}
> MOD((WEEKDAY(datevalue)+1),7)+1
> {code}
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
More information about the teiid-issues
mailing list