Welcome to Scribd. Sign in or start your free trial to enjoy unlimited e-books, audiobooks & documents.Find out more
Download
Standard view
Full view
of .
Look up keyword
Like this
1Activity
0 of .
Results for:
No results containing your search query
P. 1
Oracle tuning Table Spaces, Data Files, Redo Logfiles Related

Oracle tuning Table Spaces, Data Files, Redo Logfiles Related

Ratings: (0)|Views: 78|Likes:
Published by shubhrobhattacharya

More info:

Published by: shubhrobhattacharya on Sep 18, 2009
Copyright:Attribution Non-commercial

Availability:

Read on Scribd mobile: iPhone, iPad and Android.
download as DOC, PDF, TXT or read online from Scribd
See more
See less

09/18/2009

pdf

text

original

 
-- 0.10 QUICK INFO WITH REGARDS TO TABLESPACES, DATAFILES, REDOLOGFILES etc..:-- ------------------------------------------------------------------------------- online redo log informatie: V$LOG, V$LOGFILE:SELECT l.group#, l.members, l.status, l.bytes, substr(lf.member, 1, 50) FROM V$LOG l,V$LOGFILE lf WHERE l.group#=lf.group#;SELECT THREAD#, SEQUENCE#, FIRST_CHANGE#, FIRST_TIME,to_char(FIRST_TIME, 'DD-MM-YYYY:HH24:MI') FROM V$LOG_HISTORY;-- WHERE SEQUENCE#SELECT GROUP#, ARCHIVED, STATUS FROM V$LOG;-- tablespace free-used:SELECT Total.name "Tablespace Name", Free_space, (total_space-Free_space)Used_space, total_spaceFROM (SELECT tablespace_name, sum(bytes/1024/1024) Free_Space FROMsys.dba_free_space GROUP BY tablespace_name) Free, (SELECT b.name, sum(bytes/1024/1024) TOTAL_SPACE FROM sys.v_$datafilea, sys.v_$tablespace BWHERE a.ts# = b.ts# GROUP BY b.name) Total WHERE Free.Tablespace_name =Total.name;SELECT substr(file_name, 1, 70), tablespace_name FROM dba_data_files;
------------------------------------------------ 0.11 AUDIT Statements:----------------------------------------------select v.sql_text, v.FIRST_LOAD_TIME, v.PARSING_SCHEMA_ID, v.DISK_READS,v.ROWS_PROCESSED, v.CPU_TIME,b.username fromv$sqlarea v, dba_users bwhere v.FIRST_LOAD_TIME > '2008-05-12'and v.PARSING_SCHEMA_ID=b.user_idorder by v.FIRST_LOAD_TIME ;------------------------------------------------- 0.12 EXAMPLE OF DYNAMIC SQL:-----------------------------------------------select 'UPDATE '||t.table_name||' SET '||c.column_name||'=REPLACE('||c.column_name||','''',CHR(7));'from user_tab_columns c, user_tables twhere c.table_name=t.table_name and t.num_rows>0 and c.DATA_LENGTH>10and data_type like '%CHAR%'ORDER BY t.table_name desc;

You're Reading a Free Preview

Download
scribd
/*********** DO NOT ALTER ANYTHING BELOW THIS LINE ! ************/ var s_code=s.t();if(s_code)document.write(s_code)//-->