OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

odata message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]


Subject: [OASIS Issue Tracker] (ODATA-784) Need to specify the behaviour of arithmetic operators on Decimal type


    [ https://issues.oasis-open.org/browse/ODATA-784?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=59502#comment-59502 ] 

Ralf Handl edited comment on ODATA-784 at 4/30/15 2:37 PM:
-----------------------------------------------------------

Just noticed that Java BigDecimal defines the preferred scale of a BigDecimal operation identically for add, sub, mul, but subtracts the scale of the divisor from the scale of the dividend:

scaleof(A div B) = scaleof(A) - scaleof(B)

See https://docs.oracle.com/javase/7/docs/api/java/math/BigDecimal.html


was (Author: ralfhandl):
Just noticed that Java BigDecimal defines the preferred scale of a BigDecimal operation identically for add, sub, mul, but subtracts the scale of the divisor from the scale of the dividend:

scaleof(A div B) = scaleof(A) - scaleof(B)

> Need to specify the behaviour of arithmetic operators on Decimal type
> ---------------------------------------------------------------------
>
>                 Key: ODATA-784
>                 URL: https://issues.oasis-open.org/browse/ODATA-784
>             Project: OASIS Open Data Protocol (OData) TC
>          Issue Type: Improvement
>          Components: OData URL Conventions
>    Affects Versions: V4.0_OS
>            Reporter: Evan Ireland
>            Priority: Minor
>             Fix For: V4.0_ERRATA03
>
>
> The rules for scale of results of decimal arithmetic operators are not specified.



--
This message was sent by Atlassian JIRA
(v6.2.2#6258)


[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]