oracle开发技术:溢出错误解决方法
Jun 07, 2016 pm 04:21 PMOracle 数值数据类型最多可存储 38 个字节的精度。当将 Oracle 数值转换 为公共语言运行库数据类型时,小数点后边的位数可能过多,这会导致此错误。 解决方法: 使用round()函数: 例如:select min(pval),max(pval),round(avg(pval),5) from hvm_data_dga .
Oracle 数值数据类型最多可存储 38 个字节的精度。当将 Oracle 数值转换
为公共语言运行库数据类型时,小数点后边的位数可能过多,,这会导致此错误。
解决方法:
使用round()函数:
例如:select min(pval),max(pval),round(avg(pval),5) from hvm_data_dga .
round(avg(pval),5) 使数值小数点后按照四舍五入保留5位。
select round(32/14, 3) from dual;
输出结果:2.286
select round(32/14, 2) from dual;
输出结果:2.29

Hot Article

Hot tools Tags

Hot Article

Hot Article Tags

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics

Solution to Windows Update prompt Error 0x8024401c error

Function to calculate the number of days between two dates in oracle

How long will Oracle database logs be kept?

The order of the oracle database startup steps is

How to see the number of occurrences of a certain character in Oracle

Oracle database server hardware configuration requirements
