Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: rowtype assignment in trigger

Re: rowtype assignment in trigger

From: Rajesh Parab <rajeshparab_at_yahoo.com>
Date: 29 Jul 1999 09:46:19 -0500
Message-ID: <37a05b2b@discussions>

Titus Leskien <tle_at_noell.de> wrote:
>Hello,
>
>i want to assign not only a single value of
a column but a whole
>tablerow to a variable in a
>trigger.
>
>This was my approach, which didn't works:
>
>create trigger test
>before update on testtable
>for each row
>declare
> test_row test%rowtype;
>begin
> test_row := :new;
>end;
>
>Can anybody help me solving this without
writing a statement for every
>column (our tables have many
>cols!)
>
>Thanks
>
>Titus Leskien
>
>
>Sent via Deja.com http://www.deja.com/
>Share what you know. Learn what you don't.

:new & :old are syntactically treated as ROWTYPE datatypes, but in reality they are not. You will have to access individual fields. Received on Thu Jul 29 1999 - 09:46:19 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US