Oracle 的 Round 函數(四舍五入)函数
该函数用来返回一个四舍五入后的值
SELECT ROUND( number, [ decimalplaces ] ) from DUAL
參數:
必填项:number : 要处理的数值(数值表达式)
可选项:decimalplaces : 四舍五入时取的小数的位数,不填则返回整数
Sample :
select round(123.456) from dual; 得到 123
select round(123.456, 0) from dual; 得到 123
select round(123.456, 1) from dual; 得到 123.5
select round(123.456, 2) from dual; 得到 123.46
select round(123.456, 3) from dual; 得到 123.456
select round(-123.456, 2) from dual; 得到 -123.46
param = round(123.456,2) 即把123.456经四舍五入保留两位小数后的值123.46赋值给变量param
相关文档:
通过oracle 11g 连接mssql 2005 报下面的错误
select * from maintanance@mssql
*
第 1 行出现错误:
ORA-28545: 连接代理时 Net8 诊断到错误
Unable to retrieve text of NETWORK/NCR message 65535
ORA-02063: 紧接着 2 lines (起自 MSSQL)
oracle 11g listener.ora配置如下:
# listener.ora Network Configurati ......
关键字: oracle job 间隔时间 trunc
假设你的存储过程名为PROC_RAIN_JM
再写一个存储过程名为PROC_JOB_RAIN_JM
内容是:
Create Or Replace Procedure PROC_JOB_RAIN_JM Is li_jobno Number; &nb ......
http://www.csip.com.cn/88/n-52488.html
关于分区表和分区索引(About Partitioned Tables and Indexes)对于10gR2而言,基本上可以分成几类:
Range(范围)分区
Hash(哈希)分区
List(列表)分区
以及组合分区:Range-Hash,Range-List。
对于表而言(常规意义上的堆组织表),上述分区形式都可以应用(甚至可以对某个 ......
1.oracle字符集问题:
数据库字符集为ZHS16BGK,汉字在数据库存放的时候占用两个字节
数据库字符集为UTF8,汉字在数据库里存放的时候占用三个字节
由于字符集不同,导致现在数据库IMP的时候有些表的字段长度不够,出现ORA-12899: value too large for column的错误。
通过修改字符集可以解决这种问题。
2.utf-8和unico ......
(1)以SYS身份登陆
conn sys/sysem_pwd as sysdba;
(2)创建amly用户
create user amly identified by 9imly;
(3)创建表空间
create tablespace ts_amly datafile 'd:\amlyfile\test.dbf' size 100M;
(4)将表空间分配给用户
alter user amly default tablespace ts_amly;
(5)给用户授权
grant create sess ......