Create a trigger on Oracle Databae that updates the field in a table when a field in onether table i
Posted
by GigaPr
on Stack Overflow
See other posts from Stack Overflow
or by GigaPr
Published on 2010-04-20T19:41:22Z
Indexed on
2010/04/20
19:53 UTC
Read the original article
Hit count: 188
Hi,
i have two tables
Order(id, date, note)
and
Delivery(Id, Note, Date)
I want to create a trigger that updates the date in delivery when the date is updated in Order
I was thinking to do something like
CREATE OR REPLACE TRIGGER your_trigger_name
BEFORE UPDATE
ON Order
DECLARE
BEGIN
UPDATE Delivery set date = ??? where id = ???
END;
How do i get the date and row id?
thanks
© Stack Overflow or respective owner