显式游标_cursor is_open_fetch_close
scott>--显式游标(定义_打开_提取_关闭)scott>declare 2 cursor c_emp is select ename from emp; 3 v_ename emp.ename%type; 4 begin 5 open c_emp; 6 ...
oracle plsql(一)_binary_float_binary_double
plsql的数据类型,用于复杂的科学计算,32bit大小 SQL> r 1 declare 2 v_pls_integer pls_integer:=-100042578; 3 begin 4 dbms_output.put_line(to_char(v_...
SP2-0678: Column or attribute type can not be displayed by SQL*Plus
SQL> select * from t_blob;SP2-0678: Column or attribute type can not be displayed by SQL*PlusSQL> desc t_blob; Name &n...
oracle plsql package_body_procedure_构建语法_sp_存储过程
SQL> create or replace package pkg_E_TEACHERLOGININFO #定义包 #包中定义各种存储过程及类型名字及输入输出参数,具体处理逻辑在包体中编写 2 3 as 4 &nb...
ultraedit_notepad文件_windows编辑工具_字符集
突然灵机一动,可以在windows上用各类工具处理后,另存为时,选择存储为指定的字符集啊,原则是与oracle的数据库字符集要一致,不然会有乱码. 再次上传用sqlplus %/oracle/from_li.sql一切ok...
oracle数据类型data type与存储空间大小(二)
SQL> desc t_col_type; Name &...
oracle数据类型data type与存储空间大小(一)
SQL> desc t_seq;####查看表结构 Name &nbs...
oracle sequence语法
SQL> create sequence seq_1 start with 1 increment by 1 nomaxvalue;Sequence created.SQL> alter sequence seq_1 cache 1000;Sequence altered.SQL> alter sequence seq_1 order;Sequence altered.SQL> des...
在rhel5上oracle 10.2.0.4 上dbca silent删除数据库
dbca -help #查看dbca命令行使用信息 -bash-3.1$ dbca -silent -deleteDatabase -sourceDB test -sysDBAUserName sys -sysDBAPassword systemConnecting to database4% complete9% complete14% ...
dbms_rowid之dbms_rowid.rowid_info存储过程使用(in out)
ROWID_INFO ProcedureThis procedure returns information about a ROWID, including its type (restricted or extended), and the components of the ROWID. This is a procedure, and it cannot be...
oracle function函数cast
由于项目原因,里面insert语句用到cast转换数据类型select cast(要转换的源列 as 要转换的目标数据类型) from 要转换的表附上官方手册,可以转换内建,集合,array,nested及多集到对应的数据类型以下为cast类型...
同事编写的sql脚本文件上传到oracle 上显示乱码_字符集
公司发给我一个批量的insert 脚本,在windows上可以正常显示,其中sql脚本内容: INSERT INTO C_StatIPInfo (AreaID, StartIP, EndIP, AreaName, Memo) VALUES (N'0000000000000007', 50331647, 67108862, N'美国 新...
编写电子书包平台所有表主键之存储过程_sp_stored procedure
#有了一点写存储过程的思路,花几个小时,人真笨declarev_max_id number;beginselect max_id into v_max_id from t_max_id where tname='&table';update t_max_id set max_id=v_max_id+1; &nbs...
cursor_显式游标_与rhel5的性能关系_plsql_存储过程_sp_procedure
#定义测试表create table t_max_id(tname varchar2(30),max_id number); #经测试,显式游标的性能太差了,服务器一下了就慢好多,不能用了create or replace procedure p_get_table_max_id(v_table_name varcha...
alter table using index
#下列指定using index的行为,用于添加主键约束时,如果索引存在,就把索引与主键关联; 也可以指定建立索引的语句,或者不指定具体的索引,如果不存在,会默认建立与主键约束同名的索引Using Indexes to Enforce Con...
oracle10.2.0.4_create table_constraint_index
SQL> create table t_using(a int constraint con_not_null not null,b char(10) 2 constraint con_uni unique,c int constraint con_check check(c>10));Table created.SQL> select index_name,index...
如何优化oracle pga
1* select * from v$pga_target_advicePGA_TARGET_FOR_ESTIMATE PGA_TARGET_FACTOR ADV BYTES_PROCESSED ESTD_EXTRA_BYTES_RW ESTD_PGA_CACHE_HIT_PERCENTAGE ESTD_OVERALLOC_COUNT----------------------- -------...
rhel5 oracle10.2.0.4_alter tablespace_扩展autoextend
#这种方式创建的表空间不能自动扩展create tablespace test datafile '/oracle/oradata/yisile/test1.dbf' size 20m; 开启以上表空间的自动扩展alter database datafile file_id autoextend on; 查...
在开发库rhel5 oracle10.2.0.4上执行dbms_metadata.get_ddl报错ORA-39212
SQL> select dbms_metadata.get_ddl('TABLESPACE','SYSTEM') from dual;ERROR:ORA-39212: installation error: XSL stylesheets not loaded correctlyORA-06512: at "SYS.DBMS_SYS_ERROR", line 79ORA-06512: at "SY...
redhat5(rhel5)_ipcs详解_转
http://space.itpub.net/8554499/viewspace-580478