04_rollback_test.sql 670 B

12345678910111213141516171819202122232425
  1. set define off
  2. set echo on
  3. whenever sqlerror exit sql.sqlcode
  4. alter session set container=ORCLPDB;
  5. alter session set current_schema=PMS_TEST;
  6. begin
  7. delete from GRJJ
  8. where GRJJID in (select GRJJID from PMS_FJYRJC_CSSG1_CREATED_20261119
  9. where GRJJID is not null);
  10. update QZ q
  11. set FWC = (select b.FWC from PMS_FJYRJC_CSSG1_QZ_BAK_20261119 b
  12. where b.QZID=q.QZID)
  13. where exists (select 1 from PMS_FJYRJC_CSSG1_QZ_BAK_20261119 b
  14. where b.QZID=q.QZID);
  15. delete from PMS_FJYRJC_CSSG1_CREATED_20261119;
  16. commit;
  17. dbms_output.put_line('FJYRJC_CSSG1_TEST_ROLLBACK_OK');
  18. end;
  19. /
  20. exit