ctrl+s锁住sqlplus,ctrl+q解锁
参考地址:http://space.itpub.net/519536/viewspace-683635ctrl+s锁住sqlplus,ctrl+q解锁1)在SQL*Plus的Ctrl+S锁屏阶段盲打如下内容,注意不要敲错。insert into t values (1);commit;2)在另外开启的会话中查看...
什么时候考虑重建索引?
负责管理的数据库,有几个表存在每天的定时迁移数据,即DELETE比较多。在想需要不需要把索引重建下。而又找不到重建的理论依据。可以考虑用如下的思路来决定需不需要重建。切记,加上online参数,要不会阻塞 dml操...
唯一索引操作可能产生的锁
SESSION 1(SID=3254):apolloCRMG>create table wxh_tbd(id number);Table created.apolloCRMG>create unique index wxh_ind on wxh_tbd(id);Index created.apolloCRMG>insert into wxh_tbd values(1);1 row c...
TX锁的ID1如何转化为回滚段号和SLOT号
SQL> select XIDUSN,XIDSLOT,XIDSQN from v$transaction; XIDUSN XIDSLOT XIDSQN---------- ---------- ---------- &n...
设置 ddl_lock_timeout来避免truncate 报错
11G新特性。SESSION 1:SQL> insert into wxh_tbd select * from wxh_tbd where rownum<10;9 rows created. SESSION 2:SQL> alter session set ddl_lock_timeout=10;Session altered.SQL> truncate tabl...
create index online与非online在library cache lock/pin方面的区别
online 创建的时候,索引的共享池内容如下,LOCK和PIN都是0,没加任何形式的锁。BUCKET#127039 mtx=0xa275dc48(0, 294, 0): LIBRARY HANDLE:0x9ac96748 bid=127039 hid=720ff03f lmd=0 pmd=0 sta=VALD ...
PL/SQL在执行过程中,对其依赖的表,函数,过程都加lock和pin吗?
-----------创建个表sys@CRMG>create table wxh_tbd as select * from dba_objects;Table created.-----------创建两个过程,互相依赖,其中一个过程需要访问之前创建的表。create or replace procedure pinningisbe...
为表增加主键需要小心library cache lock.
现象模拟:session1:create index GLOBAL_ACCOUNT_BIZ_gid_ind on GLOBAL_ACCOUNT_BIZ ( GLOBAL_ID);alter table GLOBAL_ACCOUNT_BIZ add constraint GLOBAL_ACCOUNT_BIZ_GID_IND primary key (GLOBAL_...
ORA-00600:: [kkocxj : pjpCtx]错误
ops$admin@CRMG>explain plan for 2 select trunc(avg(in8_call_duration), 2) as in8_call_duration, 3 trunc(avg(out8_call_duration), 2) as...
数据库的登录限制该怎么实现?
想写一个触发器,根据机器名(有一个白名单表)作出判断,能不能让此用户登录,不知道该怎么写?我写了一个可貌似没有任何作用,不知道哪里有问题。user_login是白名单表。create or replace trigger restrict_login...
ORA-04021,timeout occurred while waiting to lock object
SQL> create or replace procedure binzhang_t is 2 begin &...
sql里面 写 gmt_create>每天的08:30怎么写???
select count(*) from aaa where GMT_CREATE >to_date(to_char(TRUNC(SYSDATE),'yyyy-mm-dd')||'08:30:00','yyyy-mm-dd hh24;mi:ss'); select count(*) from aaa where GMT_CREA...
修改表结构后一定会另依赖对象失效吗?
修改表结构后一定会另依赖对象失效吗?create table wxh_tbd as select * from dba_objects;Table created. create or replace PROCEDURE wxh_test_tbd 2 is ...
FLASHBACK的多版本查询
col a for 99999999999999999999select timestamp_to_scn(to_timestamp('2011-01-24 16:17:38','yyyy-mm-dd hh24:mi:ss')) a from dual; ...
连接条件字符类型不一样。
drop table wxh_tbd1;Table dropped.rop table wxh_tbd2;Table dropped.create table wxh_tbd1 (id number ,name varchar2(2000));Table created.create table wxh_tbd2 (id varchar2(1000) ,name varchar2(200...
ORA-00904,修改字段长度报错
alter table ALI_TPCRM_ACCESS_AREA modify SCOPE VARCHAR2(4000);alter table ALI_TPCRM_ACCESS_AREA modify SCOPE VARCHAR2(4000)  ...
ORA-01442,又遭遇疑难杂症
select nullable from user_tab_columns where table_name='WORKDAYTYPE';NU--YYYYYYY7 rows selected.alter table WORKDAYTYPE modify CREATOR NOT NULL;alter table WORKDAYTYPE modify ...
DSI中描述的touch算法。
纯理论介绍,有时间再做实验。2.jpg8I以后为了提升性能LRU又分为了LRU MAIN和LRU AUX.LRU MAIN上存在冷短和热端。_db_percent_hot_default 50  ...
关于working sets简单记录
一个working set由如下内容组成:1.jpg其中有我们比较熟悉的lru ,lru-w,ckpt queue.一个db_block_lru_latche保护一个working set。一个working sets至少需要包含50个buffers。每个working sets都有特定的一个db_bloc...
use_concat,NO_EXPAND提示
USE_CONCAT提示强迫优化器扩展查询中的每一个OR谓词为独立的查询块.最后合并所有查询块的结果,返回结果集给用户。但是从9.2.0后,这个提示似乎不是怎么有效了。select /*+ use_concat optimizer_features_enable(...