Oracle 查看Data Guard Apply 速度脚本 set linesize 200 col start_time format a20 col type format a16 col item format a20 col sofar format 99999 col units format a7 SELECT start_time, type, item, sofar, units FROM V$recovery_Progress where lower(item) like '%apply%' and units = 'KB/sec' ord
2018-09-19 11:53 2492 0
$ cat dba_snapshot_database_9i.sql -- +----------------------------------------------------------------------------+ -- | Jeffrey M. Hunter | -- | jhunter@idevelopment.info | -- |
2017-11-25 16:12 2810 0
-- Purpose: (dbms_sql_tune.alter_sql_profile) - disable set verify off EXEC DBMS_SQLTUNE.ALTER_SQL_PROFILE (name => '&profile_name', attribute_name => 'STATUS', value => 'DISABLED');
2017-11-23 14:05 2565 0
---------------------------------------------------------------------------------------- -- -- File name: create_sql_profile_awr.sql -- -- Purpose: creates profile for plan in AWR history -- -- Author: Kerry Osborne -- -- Usage: This scripts prompts for five values. -- --
2017-11-23 14:04 2898 0
---------------------------------------------------------------------------------------- -- -- File name: create_sql_profile.sql -- -- Purpose: Create SQL Profile based on Outline hints in V$SQL.OTHER_XML. -- -- Author: Kerry Osborne -- -- Usage: This scripts prompts for fou
2017-11-23 14:04 2974 0
---------------------------------------------------------------------------------------- -- -- File name: create_baseline.sql -- -- Purpose: Creates a SQL Baseline on a SQL statement in the shared pool. - -- Author: Kerry Osborne -- -- Usage: This scripts prompts for four va
2017-11-23 14:02 2516 0
-- Purpose: Find SQLs with SQL baseline set lines 155 col sql_text for a50 trunc col last_executed for a28 col enabled for a7 col plan_hash_value for a16 col last_executed for a16 select spb.sql_handle, spb.plan_name, spb.sql_text, spb.enabled, spb.accepted, spb.fixed, to_char(spb.last
2017-11-23 14:02 2287 0
-- Purpose: shows stats (avg_etime, avg_lio, etc) for statements by plan -- Note that I have modified this script slightly to include snaps with 0 executions. -- This is to account for situations with very long running statements (that generally -- cross snapshot boundaries). In these situati
2017-11-23 14:01 3032 0
set lines 155 col execs for 999,999,999 col avg_etime for 999,999.999 col avg_lio for 999,999,999.9 col begin_interval_time for a30 col node for 99999 break on plan_hash_value on startup_time skip 1 select ss.snap_id, ss.instance_number node, begin_interval_time, sql_id, plan_hash_value, nvl
2017-11-23 14:00 2871 0
SPO coe_load_sql_profile.log; SET DEF ON TERM OFF ECHO ON FEED OFF VER OFF HEA ON LIN 2000 PAGES 100 LONG 8000000 LONGC 800000 TRIMS ON TI OFF TIMI OFF SERVEROUT ON SIZE 1000000 NUM 20 SQLP SQL>; SET SERVEROUT ON SIZE UNL; REM REM $Header: 215187.1 coe_load_sql_profile.sql 11.4.5.5 2013/03/01
2017-11-23 13:58 3701 0
select sql_id from DBA_HIST_ACTIVE_SESS_HISTORY where session_id=1170 and snap_id=12738 and instance_number=1; select snap_id from dba_hist_snapshot where END_INTERVAL_TIME> to_timestamp('2012-9-7 11:30:00','yyyy-mm-dd hh24:mi:ss') and END_INTERVAL_TIME< to_timestamp('2012-9-7 14:00:00','
2017-09-27 13:20 4087 0
SELECT /*+ ordered */ p.spid, s.sid, s.serial#, s.username, TO_CHAR(s.logon_time, 'mm-dd-yyyy hh24:mi') logon_time, s.last_call_et, st.value, s.sql_hash_value, s.sql_address, sq.sql_text FROM v$statname sn, v$sesstat st, v$process p, v$session s, v$sql sq WHERE s.paddr = p.a
2017-09-27 13:18 2867 0
查看哪些对象引用了表或其他对象:REFERENCED_NAME=’T_BIM_ORG’; set lin 200 set pagesize 200 col REFERENCED_NAME for a20 col OWNER for a15 col name for a40 col REFERENCED_TYPE for a20 col REFERENCED_NAME for a30 SELECT OWNER,NAME,TYPE,REFERENCED_NAME,REFERENCED_TYPE,DEPENDENCY_TYPE FROM DBA_DEPENDENCIES WHERE R
2017-09-27 10:55 2554 1
查看逻辑读前10的SQL: SET LINESIZE 300; SET PAGESIZE 300; SET LONG 50000; SELECT * FROM ( SELECT sql_fulltext AS sql, SQL_ID, buffer_gets / executions AS "Gets/Exec", buffer_gets, executions FROM V$SQLAREA
2017-06-09 16:52 4280 0
select a.sid,spid,status,substr(a.program,1,40) prog, a.terminal,osuser,value/60/100 value from v$session a,v$process b,v$sesstat c where c.statistic#=12 and c.sid=a.sid and a.paddr=b.addr order by value desc
2017-02-24 17:40 2952 0
人的一生应该是这样度过的:当他回首往事的时候,他不会因为虚度年华而悔恨,也不会因为碌碌无为而羞耻;这样,在临死的时候,他就能够说:“我的整个生命和全部精力,都已经献给世界上最壮丽的事业....."
ACE 搜索
中国ORACLE用户组
中国DBA联盟(ACDU)· 核心伙伴
墨天轮 · MVP
CNDBA_2: 142216823(2k群)
CNDBA_3: 283816689(2k群)
CNDBA_4: 391125754
CNDBA_5: 104207940
CNDBA_6: 62697977