A reader, March 15, 2021 - 5:28 pm UTC
Thank you for your answer.
I agree exactly with what you said.
The delete code is auto generated so I can not change it.
I solved the problem with a compound trigger which creates a temp table in the row level part and then the delete in the statement-level trigger based on the data obtained in the temp table.
INSTEAD OF TRIGGER?
Dieter, March 15, 2021 - 6:56 pm UTC
If you have a view v_tab_a on the table tab_a and the generated DML is on the view, you could also use an INSTEAD-OF-TRIGGER:
create table tab_a (id varchar2(10));
create view v_tab_a as select lower(id) id from tab_a;
CREATE OR REPLACE TRIGGER del_tab_a
INSTEAD OF DELETE ON v_tab_a
FOR EACH ROW
DELETE FROM tab_a a
WHERE upper(a.id) = upper(:old.id);
insert into tab_a (id) values ('ABC');
select * from v_tab_a;
delete from v_tab_a where id = 'abc';
A reader, March 18, 2021 - 12:35 pm UTC
The instead of trigger looks like a very nice bit of code.