10.1.0.5下调优遇到的奇怪问题
客户为一数据仓库应用(1)10053居然无法做跟踪,搞不懂,并且sql是第一遍硬解析执行。alter session set events'10053 trace name context forever,level 1';.trc里什么都没有,只有那个sql.(2)执行select my_report.my_item_je_sum(20070117,5555,6666) from dual;函数内含有以下语句:select sum(nvl(f.dr_cny, 0) - nvl(f.cr_cny, 0)) from dw_fact f where f.account_tl like '5555%' and f.accounting_entity_id =6666 and f.time_id between 20070101 and 20070117;但就是不走位图索引,但se
一条大sql的调优
这是某个DW应用里的大sql,原来据说5分钟就执行完了,现在居然要5个小时,看看情况吧: SELECT r_Time.time_id, ae.accounting_entity_id, cs.vendor_id, ai.account_item_id, ta.target_account_id, rf.previous_balance PERIOD_BEGIN_BALANCES, rf.balance PERIOD_net_BALANCES FROM ( -- Part 1/2, Uncleared & overdue documents when it's calaculation day SELECT bsik.shkzg, bsik.dmbtr, bsik.zfbdt, bsik.bukrs,
order by为什么没用colA上的索引?
select * from ( select * from tableA order by colA)where rownum<10colA原来不是null列,只有not null列才可能在索引中有记录,优化器没办法用索引了,改成not null,OK。[@more@]
hp-ux环境sqlplus中使用@运行sql脚本报错
hp-ux环境,在sqlplus中运行@xyz.sql,报错,@居然不行,还是用start吧SQL> @/oracle/app/oracle/product/9.2.0/rdbms/admin/spreport.sql';SP2-0734: unknown command beginning "/oracle/ap..." - rest of line ignored.SQL> @'/oracle/app/oracle/product/9.2.0/rdbms/admin/spreport.sql';SP2-0734: unknown command beginning "'/oracle/a..." - rest of line ignored.SQL> @/oracle/app/oracle/product/9.2.0/rdbms/admin/spreport.sql;SP2-0734: unknown command beginning "/oracle/ap..."
commit时表内容清空
一客户打电话过来说,我的一张表,为什么插入一条数据,再提交,数据就没了,怎么回事呀?insert into faretemp values ('1','1',1,'1','1');commit;突然愣了一秒钟,接着才缓过劲来,是不是临时表呀?那哥们看了一下,“是的”。“这默认提交时数据就清掉了”。真是“我不做开发好多年,”[@more@]