Next
Topic:Characteristics of Numeric Data Types |

SAND CDBMS follows the SQL92 standard in regards to the data types returned by arithmetic and aggregate operations, except in the following cases:

- SUM ([DISTINCT]
expression) – an INTEGER or SMALLINT expression returns DECIMAL (20,0).- AVG ([DISTINCT]
expression) – an INTEGER or SMALLINT expression returns FLOAT.- division – a FLOAT value is returned if an INTEGER or SMALLINT value is the divisor and dividend. That is:

- INTEGER / INTEGER = FLOAT
- INTEGER / SMALLINT = FLOAT
- SMALLINT / SMALLINT = FLOAT
- SMALLINT / INTEGER = FLOAT