dynamobi/dynamobi — Issue #824: [FRG-46] decimal arithmetic does not handle overflow
Author: dynamobi-build
Created: 2011-12-30 03:51:07+00:00
State: open
Labels: FRG

[reporter="schoi", created="Thu, 16 Feb 2006 16:11:55 -0500 (GMT-05:00)"]
related to LDB-21, but not sure if a fix for that will automatically fix this too..

With any decimal overflow, there is no exception or warning; the overflow value is just stored and/or returned.

Repro:

------------

create schema s;

set schema 's';

create table t1(a decimal(19,18) primary key);

insert into t1 values(1);

-- below queries should throw exceptions but don't:

select a+10 from t1;

+------------------------+

| EXPR$0 |

+------------------------+

| -7.446744073709551616 |

+------------------------+

insert into t1 values(10);

select * from t1;

+------------------------+

| A |

+------------------------+

| -8.446744073709551616 |

| 1.000000000000000000 |

+------------------------+