当前位置:数据库 > Oracle >>

【Oracle】-【隐式commit】-正常与异常退出对commit的作用

【Oracle】-【隐式commit】-正常与异常退出对commit的作用
 
create table my_objects as select * from all_objects;
commit;
select count(*) from my_objects;
 
 
  COUNT(*)
----------
      8587
 
 
delete from my_objects;
8587 rows deleted.
 
 
exit
 
再次登录,
select count(*) from my_objects;
  COUNT(*)
----------
         0
 
说明:
 
正常退出sqlplus(如用exit),会执行commit;
 
异常退出sqlplus(如用alter system kill session 'sid,serial#'),会执行rollback。
 
CopyRight © 2022 站长资源库 编程知识问答 zzzyk.com All Rights Reserved
部分文章来自网络,