db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Kristian Waagan (JIRA)" <j...@apache.org>
Subject [jira] Commented: (DERBY-3874) Document numeric function ATAN2(float1,float2)
Date Mon, 22 Sep 2008 21:24:44 GMT

    [ https://issues.apache.org/jira/browse/DERBY-3874?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12633508#action_12633508
] 

Kristian Waagan commented on DERBY-3874:
----------------------------------------

> On the JDBC escape functions the defined list is specified by appendix C.1 of the JDBC
spec. If a function does not appear in that appendix then it should not work as a JDBC escaped
function. 

Derby doesn't behave correctly, DERBY-591 has been logged related to this: "Several builtin
functions are incorrectly exposed through the JDBC escaped function syntax {fn <function_call>}"

On the documentation issue, I think it would be good to mention that the function will throw
an exception with SQL state 2003 when the resulting value or the arguments are out of range.
I suppose the Java API docs can be used to determine these cases, although I don't know for
sure if this is the correct definition/specification to use for ATAN2.
This is the code checking the arguments (NumberDataType.normalizeDOUBLE):
        if ( (Double.isNaN(v) || Double.isInfinite(v)) ||
             ((v < Limits.DB2_SMALLEST_DOUBLE) || (v > Limits.DB2_LARGEST_DOUBLE)) ||
             ((v > 0) && (v < Limits.DB2_SMALLEST_POSITIVE_DOUBLE)) ||
             ((v < 0) && (v > Limits.DB2_LARGEST_NEGATIVE_DOUBLE)) )

Thanks for looking into documenting the function, Kim.

> Document numeric function ATAN2(float1,float2)
> ----------------------------------------------
>
>                 Key: DERBY-3874
>                 URL: https://issues.apache.org/jira/browse/DERBY-3874
>             Project: Derby
>          Issue Type: Sub-task
>          Components: Documentation
>    Affects Versions: 10.5.0.0
>            Reporter: Kristian Waagan
>            Assignee: Kim Haase
>
> Document the numeric function ATAN2(float1,float2).
> Mentioned in the JDBC specification, appendix C.1.
> Implementation documented by the JavaDoc for StrictMath.atan2.
> According to the JDBC specification, table B-1, a JDBC float maps to a Java double.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message