You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tajo.apache.org by "Hyunsik Choi (JIRA)" <ji...@apache.org> on 2013/12/01 10:38:35 UTC
[jira] [Commented] (TAJO-350) Implement round, floor, ceil
[ https://issues.apache.org/jira/browse/TAJO-350?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13835991#comment-13835991 ]
Hyunsik Choi commented on TAJO-350:
-----------------------------------
+1
The patch and unit tests look nice for me.
> Implement round, floor, ceil
> ----------------------------
>
> Key: TAJO-350
> URL: https://issues.apache.org/jira/browse/TAJO-350
> Project: Tajo
> Issue Type: New Feature
> Components: operator/function/udf
> Reporter: hyoungjunkim
> Assignee: hyoungjunkim
> Priority: Minor
> Fix For: 0.8-incubating
>
> Attachments: TAJO-350.patch
>
>
> h3. Function Definition
> {code}
> INT8 round(value FLOAT8)
> INT8 floor(value FLOAT8)
> INT8 ceil(value FLOAT8)
> {code}
> h3. Example
> round
> {code}
> select round(5.1) => 5
> select round(5.5) => 6
> select round(5.6) => 6
> select round(-5.1) => -5
> select round(-5.5) => -6
> select round(-5.6) => -6
> {code}
> floor
> {code}
> select round(5.1) => 5
> select round(5.5) => 5
> select round(-5.1) => -6
> select round(-5.6) => -6
> {code}
> ceil
> {code}
> select round(5.1) => 6
> select round(5.5) => 6
> select round(-5.1) => -5
> select round(-5.6) => -5
> {code}
--
This message was sent by Atlassian JIRA
(v6.1#6144)