Engage with tech pros in our community with native advertising, as a Vendor Expert, and more.
ORA-04088: error during execution of trigger 04091. 00000 - "table %s.%s is mutating, trigger/function may not see it" *Cause: A trigger (or a user defined plsql function that is referenced in this statement) attempted to look at (or modify) a table that was in the middle of being modified by the statement which fired it. *Action: Rewrite the trigger (or function) so it does not read that table.
create or replace TRIGGER "update_date" BEFORE INSERT ON "scott"."data_list" REFERENCING OLD AS OLD NEW AS NEW FOR EACH ROW declare numbr number; begin begin select count(*) into numbr from t_values s where s.val = :new.val and s.Date_from = TO_DATE('31.12.2100','DD.MM.YYYY'); end; if numbr > 0 then begin update t_values s set Date_from = :new.date_to -1 where s.val = :new.val and s.Date_from = TO_DATE('31.12.2100','DD.MM.YYYY'); end; end if; end;
INSERT INTOdata_list ( val, date_from, date_to, mid_val, user, date ) ( SELECT a.VAL, A.date_from, A.date_to, A.mid_val, 'test_usr', a.date FROM temp_table A);
|List of database solutions that offer High Availability / Failover / Mirroring solutions||5||67|
|The purpose of an index when the key is unique||10||72|
|Formatting varchar to numeric||8||58|
|how to reset the password in Oracle 11g Express Edition||4||32|
Join the community of 500,000 technology professionals and ask your questions.
Connect with top rated Experts
27 Experts available now in Live!