Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Summation
You waBrice Toth wrote:
>
> Hi. I'm relatively new to Oracle and SQL. My question
> is this: I have a table with columns x and y which are
> both integer values. i need to get the sum of the values
> in x and in y to put into column z. i need the sum to
> occur automatically whenever the values in x and y change.
> Can anyone help as to how to do this? Thanks a lot.
>
> Brice Toth
> bat107_at_psu.edu
You want to create an update trigger for the table--a "for each row" trigger which sets :new.z := :new.x + :new.y Received on Sat Mar 22 1997 - 00:00:00 CST
![]() |
![]() |