Oracle数据库管理员职责(四)
2008-09-20 12:55:16 来源:WEB开发网2. analyze_comp.sql
analyze_comp.sql
BEGIN
SYS.DBMS_UTILITY.ANALYZE_SCHEMA('&OWNER','COMPUTE');
END;
/
3. pop_vol.sql
pop_vol.sql
insertintoutl_vol_facts
selecttable_name
,NVL(num_rows,0)asnum_rows
,trunc(last_analyzed)asmeas_dt
fromall_tables
or just user_tables
whereownerin('&OWNER')
or a comma-separated list of owners
/
commit
/
C.每周处理程序
1. nextext.sql
nextext.sql
To find tables that don't match the tablespace default for NEXT extent.
The implicit rule here is that every table in a given tablespace should
use the exact same value for NEXT, which should also be the tablespace's
default value for NEXT.
his tells us what the setting for NEXT is for these objects today.
11/30/98
SELECTsegment_name,segment_type,ds.next_extentasActual_Next
,dt.tablespace_name,dt.next_extentasDefault_Next
FROMdba_tablespacesdt,dba_segmentsds
WHEREdt.tablespace_name=ds.tablespace_name
ANDdt.next_extent!=ds.next_extent
ANDds.owner=UPPER('&OWNER')
ORDERBYtablespace_name,segment_type,segment_name;
2. existext.sql
- ››oracle 恢复误删除的表和误更新的表
- ››Oracle分页查询排序数据重复问题
- ››Oracle创建dblink报错:ORA-01017、ORA-02063解决
- ››Oracle 提高SQL执行效率的方法
- ››Oracle 动态查询,EXECUTE IMMEDIATE select into...
- ››Oracle 11g必须开启的服务及服务详细介绍
- ››oracle性能34条优化技巧
- ››oracle数据库生成随机数的函数
- ››Oracle 数据库表空间容量调整脚本
- ››oracle单库彻底删除干净的方法
- ››Oracle创建表空间、创建用户以及授权、查看权限
- ››oracle 中 UPDATE nowait 的使用方法
赞助商链接