2016年1月13日
摘要: create or replace procedure SP_Change_Sequence_Num(table_name_in varchar2, pk_name_in varchar2, is_positive_growth_in number) is /*********************************************************** ... 阅读全文
posted @ 2016-01-13 12:01 思静 阅读(436) 评论(0) 推荐(0) 编辑
摘要: SELECT SQL_ID, SQL_TEXT,FIRST_LOAD_TIME, EXECUTIONS FROM V$SQLAREA where SQL_ID='22v8fyk0juw25'; 阅读全文
posted @ 2016-01-13 11:54 思静 阅读(2712) 评论(0) 推荐(0) 编辑
摘要: SELECT name, value FROM v$parameter WHERE name like '%target%'; select value/1024/1024/1024 as Value_G from dual; select * from V$MEMORY_TARGET_ADVICE; SELECT ( (SELECT SUM(value) FROM V$... 阅读全文
posted @ 2016-01-13 11:51 思静 阅读(151) 评论(0) 推荐(0) 编辑
摘要: 有时候创建索引或修改表字段时,会提示资源正忙,可以查出表对应的进程并kill掉 select l.session_id,o.owner,o.object_name from v$locked_object l,dba_objects o where l.object_id=o.object_id; select t2.username,t2.sid,t2.serial#,t2.logon... 阅读全文
posted @ 2016-01-13 11:49 思静 阅读(429) 评论(0) 推荐(0) 编辑
摘要: alter system set inmemory_size=4G scope=spfile; alter table table_name inmemory; alter table table_name no inmemory; select * from v$inmemory_area; 阅读全文
posted @ 2016-01-13 11:48 思静 阅读(214) 评论(0) 推荐(0) 编辑
摘要: -- invalid object statistics: select owner, object_type, status, count(*) from dba_objects where status='INVALID' group by owner, object_type, status order by owner, object_type; -- select inval... 阅读全文
posted @ 2016-01-13 11:46 思静 阅读(392) 评论(0) 推荐(0) 编辑
摘要: -- 硬解析的 parse count (hard) select * from v$sysstat where name like '%parse%'; select a.value,b.name from v$mystat a, v$statname b where a.STATISTIC#=b.STATISTIC# and b.name like '%parse%'; selec... 阅读全文
posted @ 2016-01-13 11:42 思静 阅读(3244) 评论(0) 推荐(1) 编辑
摘要: SQL> exec dbms_xdb_config.sethttpport(8087); 打开OEM: http://DBSIPOrName:8087/em/ 阅读全文
posted @ 2016-01-13 11:38 思静 阅读(1094) 评论(0) 推荐(0) 编辑
摘要: create table sequence( name varchar(50) not null primary key, current_value BIGINT not null DEFAULT 0, increment int not null DEFAULT 1, max_value BIGINT, -- 最大值 initial_value BIGIN... 阅读全文
posted @ 2016-01-13 11:27 思静 阅读(2697) 评论(0) 推荐(0) 编辑