oracle触发器插入一条数据并根据这条数据的某个字段查询第三张表然后把查询结果插入另外一张表

2024-12-31 01:55:17
推荐回答(1个)
回答1:

create or replace trigger trg_c_a
after insert on a
referencing new as new old as old
for each row
begin
insert into c
select :new.id,b.id ,:new.name1,:new.password1
from b
where b.describe=:new.describe;
end;