Stackpack的使用
Statspack是Oracle 8i以上提供的一个非常好的性能监控与诊断工具,基本上全部包含了BSTAT/ESTAT的功能,更多的信息可以参考附带文档$ORACLE_HOME/rdbms/admin/spdoc.txt。 STATSPACK文件:SPDOC.TXT 安装运行...
?计算2个日期之间的工作日(备以后使用)
计算2个日期之间的工作日SELECT COUNT(*) FROM (SELECT olddate + ROWNUM - 1 RN FROM DUAL CONNECT BY ROWNUM <= newdate - olddate)WHERE TO_CHAR(RN, 'D') BETWEEN 2 AND 6...
【故障处理】ORA-00119: invalid specification for system parameter LOCAL_LISTENER
今天一同事反映他在windows下更换用户后数据库数据库无法启动报如下错误:ORA-00119: invalid specification for system parameter LOCAL_LISTENERORA-00132: syntax error or unresolved network name 'LIS...
RMAN异库恢复之EM(1)
用rman恢复数据库到异机后,重新创建EM.遇到的第一个错误./home/oracle 11:43 $cat /oracle/database/product/10.2.0/db_1/cfgtoollogs/emca/testdb1/emca_repos_drop_2011-02-10_11-25-29-上午.log [10-02...
11g单机创建database control遇到的问题
11g database 单机创建database control,遇到问题:(1) listener 没起,lsnrctl start(2)日志报 没权限:orapwd 重建密码文件(3)ORACLE_UNQNAME export ORACLE_UNQNAME=$ORACLE_SID (4)手工建库后,有些脚本没执行:补执行(看提示)Connected to an idle instance.SQL> startup ;ORACLE insta...
手工建库 ORA-00845: MEMORY_TARGET not supported onthis system
按照官方文档,手工建库,不熟悉,碰到一些问题,记下。手工建库碰到的问题:1.ORA-00845: MEMORY_TARGET not supported on this system(调整memory_target大小)2.create database ORA-01034: ORACLE not available???(没有nomount)3.已经创建了控制文件--(干掉控制文件)4.不可以创建文件--(创建相应的目录)5.建表语...
1Z0-050题库整理206道
今天通过了050考试,将此前整理的题库整理如下,考试中有两三道题不在题库中;如需考试,将题库看熟,应该没问题;QUESTION 1SQL>ALTER SYSTEM SETdb_securefile = 'IGNORE';A. It forces SecureFiles to becreated even if the BASICFILE option is specified to create the LOB.C. It does not allow ...
解决ORA-28002: the password will expire within 6 days的问题
解决ORA-28002: the password will expire within 6 days的问题 现象描述: 登陆oracle 11g提示ERROR:ORA-28002: the password will expire within 6 days 告警信息:ERROR: ORA-28002: the password will expire within 1 days 原因分析:oracle11g中默...
Understanding METHOD_OPT=> 'for all columns size'
version 1:method_opt:决定histograms信息是怎样被统计的 method_opt参数尤其适合在表和索引数据发生变化时刷新统计数据。method_opt参数也适合用于判断哪些列需要直方图。 某些情况下,索引内的各个...
Oracle直方图详解(ZT)
当系统中的某些表存在高度不均匀的数据分布时,使用柱状图能够产生更好的选择性评估,从而产生更加优化的执行计划。柱状图提供一种有效和简捷的方法来呈现数据的分布情况。[@more@]下面通过一个具体的例子解释柱状图的使用。SQL> create table tab (a number, b number);Table created.SQL> begin for i in 1..10000 loop insert into tab values (i, i); end loop; commit; end; /PL/SQL procedure successfully completed.SQL> update tab set b=5 where b between 6 and 9995;99
oracle统计信息和直方图
oracle统计信息和直方图的理解[@more@]以前一直对统计信息的理解就是对行的数据分布的,提供改CBO来选择高效的执行计划。这段时间看了不少资料,对统计有了一个更清晰的认识 统计信息: 1,表中的统计信息 2,索引列的统计信息 3,一般列的统计信息 表的统计信息:1,表行数,使用的块数,空的块数,块的使用率,行迁移和链接的数量,pctfree,pctused的数据,行的平均大小 Code highlighting produced by Actipro CodeHighlighter (freeware) http://www.CodeHighlighter.com/ -->se
table 函数知道
将聚合类型转为单列CREATE TYPE v as table of varchar2(4000);select * from table(V('a','b','c'));COLUMN_VALUE--------------abc
concept 点点滴滴1
1.Full table scans 全表扫描This type of scan reads all rows from a table and filters out those that do not meet the selection criteria. The database sequentially scans all data blocks in the segment, including those under the high water mark that separates used from unused space这种类型...
virtual box 克隆虚拟机
virtual box 克隆虚拟机Microsoft Windows [版本 6.1.7601]版权所有 (c) 2009 Microsoft Corporation。保留所有权利。C:\Users\ThinkPad>d:D:\>cd VirtualBoxD:\VirtualBox>VBoxManage clonehd D:\rhce\primaryguard\primaryguard.vdi D:\rhce\standbyguard\standbyguard.vdi0%...10%...20%...30%...40%...50%...60...
ORA-01116 错误
今天做测试,删除了物理文件。想关闭实例报错,下面是错误:SYS@orcl>shutdown immediate;ORA-01116: error in opening database file 4ORA-01110: data file 4: '/u01/app/oracle/oradata/orcl/disk1/build01.dbf'ORA-27041: unable to open fileLinux Error: 2: No such file or directoryAdditional information: ...
ins-13001 Minimum requirements were not met for this environment
在 rhel6.2 上面装12CR1有问题,但是看不出错在哪?google 了下,有人发帖解释为少个安装包,还是暂时放弃了,先去下个ol6装。具体解释见:http://terrancesiu.com/post/748.html
T430开启虚拟化
之前一直想装12c,但是12c目前只支持64位系统,机器是64位的机器,但是没开启虚拟化好像装不了。之前在bios里面没找到。今天终于找到了,进入bios:security-->Virtualzation-->Inter R.... ,这个就是了。我的机器T430,i5-3210M记录下。...
userenv 用法
http://www.cnblogs.com/wanglibo/articles/2121098.htmlOracle 中的Userenv() 1.USEREVN() 返回当前用户环境的信息,opt可以是:ENTRYID,SESSIONID,TERMINAL,ISDBA,LABLE,LANGUAGE,CLIENT_INFO,LANG,VSIZE1.ISDBA 查看当前用户是否是DBA如果是则返回trueSQL> select userenv(...
怎么看到 dump的不对啊,还不懂
create table test01(id int,name int);create bitmap index bm1 on test01(id);insert into test01 values(1,11);insert into test01 values(1,12);insert into test01 values(1,13);insert into test01 values...
不能把role 给它本身
查看( 98 ) / 评论( 0 ) / 评分( 0 / 0 ) 角色(role)是系统权限(system privilege)和对象权限(object privilege)的集合。Oracle为了防止角色间的循环授予,自带了检测方法。演示在此。1.清理测试环境sys@ora10g...