You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@drill.apache.org by "Mehant Baid (JIRA)" <ji...@apache.org> on 2014/06/03 23:14:03 UTC
[jira] [Commented] (DRILL-525) POWER function with integer base and
exponent returns decimal result
[ https://issues.apache.org/jira/browse/DRILL-525?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14017158#comment-14017158 ]
Mehant Baid commented on DRILL-525:
-----------------------------------
We use Java's Math.pow() to compute power which returns the result in double hence our output has a decimal point.
> POWER function with integer base and exponent returns decimal result
> ---------------------------------------------------------------------
>
> Key: DRILL-525
> URL: https://issues.apache.org/jira/browse/DRILL-525
> Project: Apache Drill
> Issue Type: Bug
> Components: Functions - Drill
> Affects Versions: Future
> Reporter: Krystal
> Assignee: Mehant Baid
> Priority: Minor
>
> Ran the following query in drill:
> 0: jdbc:drill:schema=dfs> select power(12, 5) from dfs.`student` where rownum = 10;
> +------------+
> | EXPR$0 |
> +------------+
> | 248832.0 |
> +------------+
> Compared to postgres, mysql and oracle, they all returned an integer of 248832
--
This message was sent by Atlassian JIRA
(v6.2#6252)