直接上代码:
create or replace trigger trigger_name
before insert on table_name
for each row
declare
expiry_date_from_temp pur_rfx_headers.creation_date%type;
begin
select h.creation_date into expiry_date_from_temp from pur_rfx_headers h
where h.rfx_number =:new.document_number;
:new.feedback_expiry_date_from := expiry_date_from_temp;
end;