Congling Xia created KYLIN-5042: ----------------------------------- Summary: floor function return wrong result for date type Key: KYLIN-5042 URL: https://issues.apache.org/jira/browse/KYLIN-5042 Project: Kylin Issue Type: Bug Affects Versions: v3.1.2 Reporter: Congling Xia Fix For: Future
floor function return wrong result for date type, for example: {code:java} select floor(current_date to YEAR), floor(cast('2021-07-01' AS DATE) to YEAR), floor(cast('2021-07-01' AS TIMESTAMP) to YEAR) {code} the result is: {code:java} EXPR$0 EXPR$1 EXPR$2 1970-01-01 1970-01-01 2021-01-01 00:00:00 {code} -- This message was sent by Atlassian Jira (v8.3.4#803005)