你好,游客 登录 注册 搜索
背景:
阅读新闻

Oracle ORA-0650 快照过旧实验

[日期:2012-02-21] 来源:Linux社区  作者:Linux [字体:大 中 小]

conn / as sysdba
create undo tablespace undotbs3 datafile 'd:\lx\undotbs03.dbf' size 2m;
alter system set undo_tablespace=undotbs3;


sess1:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drop table test_undo;
create table test_undo as select * from dba_objects where rownum<4001;


variable c refcursor;
declare
begin
  open  :c for select * from test_undo;
end;
/

--最后执行
print :c

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
sess2:

begin
  for i in (select rowid from test_undo) loop
   update test_undo set object_id=1 where rowid=i.rowid;
  end loop;
  commit;
end;
/

update test_undo set object_id=11111;

select round(sum(bytes)/1024/1024,3) from dba_Free_space where tablespace_name='UNDOTBS3';

linux
相关资讯       oracle数据库教程 
本文评论   查看全部评论 (0)
表情: 表情 姓名: 字数

       

评论声明
  • 尊重网上道德,遵守中华人民共和国的各项有关法律法规
  • 承担一切因您的行为而直接或间接导致的民事或刑事法律责任
  • 本站管理人员有权保留或删除其管辖留言中的任意内容
  • 本站有权在网站内转载或引用您的评论
  • 参与本评论即表明您已经阅读并接受上述条款