Re: New to triggers-- help on field change
Something like ...
Create Trigger After Update On User For Each Row
Insert Into BalanceHistory
Set
User_idUser_FK=OLD.user,
timestamp=Now(),
change_amount=NEW.cur_balance-OLD.cur_balance,
old_balance=OLD.cur_balance,
new_balance=NEW.balance;
but change_amount is entirely redundant, lose it.
Subject
Views
Written By
Posted
1809
December 21, 2013 03:32PM
Re: New to triggers-- help on field change
996
December 21, 2013 04:24PM
941
December 21, 2013 07:34PM
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.