ossp-pkg/as/as-db/bres/bres-history.sql 1.11 -> 1.12
--- bres-history.sql 2003/06/08 15:07:47 1.11
+++ bres-history.sql 2003/06/08 15:08:54 1.12
@@ -452,8 +452,7 @@
new.ac_hid := as_hs_make(new.ac_oid);
END IF;
RETURN new;
- END IF;
- IF TG_WHEN = ''BEFORE'' AND TG_OP = ''UPDATE'' THEN
+ ELSIF TG_WHEN = ''BEFORE'' AND TG_OP = ''UPDATE'' THEN
-- clone old entry to allow old entry to be overwritten as it would be new entry
INSERT INTO as_account VALUES (old.ac_oid, old.ac_name, old.ac_hid);
-- give new entry a new history id if not explicity set by user
@@ -461,8 +460,7 @@
new.ac_hid := as_hs_make(new.ac_oid);
END IF;
RETURN new;
- END IF;
- IF TG_WHEN = ''AFTER'' AND TG_OP = ''DELETE'' THEN
+ ELSIF TG_WHEN = ''AFTER'' AND TG_OP = ''DELETE'' THEN
-- delete corresponding history entries
PERFORM as_hs_delete(old.ac_oid, old.ac_hid);
RETURN old;
|
|