[ 
https://issues.apache.org/jira/browse/DRILL-320?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Mehant Baid updated DRILL-320:
------------------------------

    Attachment: DRILL-320.patch

Changed the rules of math functions so we model after Postgres. The output type 
would match the input type (the larger one in case of multiple inputs). For 
example if the input types to an add function are two tinyint's and we overflow 
then we simply lose the precision. We don't use a bigger holder to store the 
result of the addition nor check for overflow.

Reviewboard link: https://reviews.apache.org/r/16230/ 

> Rework MathFunctions to use codegen 
> ------------------------------------
>
>                 Key: DRILL-320
>                 URL: https://issues.apache.org/jira/browse/DRILL-320
>             Project: Apache Drill
>          Issue Type: Bug
>            Reporter: Mehant Baid
>            Assignee: Mehant Baid
>         Attachments: DRILL-320.patch
>
>
> MathFunctions.java currently contains implementation of basic math functions 
> (like add, subtract) and only contains a few of the possible implementations 
> written by hand. Need to rework this class such that we can use codegen to 
> generate all possible implementations (consisting of all input types).
> Also currently we are missing multiply and divide function implementations, 
> will add those as part of this JIRA.



--
This message was sent by Atlassian JIRA
(v6.1.4#6159)

Reply via email to