oracle四舍五入取得的数值
oracle四舍五入取得的数值SELECT ROUND( number, [ decimal_places ] ) FROM DUAL说明:number : 将要处理的数值decimal_places : 四舍五入,小数取几位,不填默认为0Sample :select round(123.456) from dual; 结果: 123select round(123.456, 0) from dual; 结果: 123select round(123.456, 1) from dual; 结果: 123.5select round(123.456, 2) from dual; 结果:123.46select round(123.456, 3) from dual; 结果: 123.456select round(-123.456, 2) from dual; 结果:-123.46