Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Before insert trigger, weird problem
Igor,
Do not use the colon in front of new. Oracle thinks it's trying to use a bind variable.
Just use :
begin
new.COLUMNNAME := SOME_VALUE_HERE; end;
Igor Sereda wrote in message <353E32F9.ABC3B4BE_at_spb.runnet.ru>...
>Hello,
>
>There's a strange problems when attempting to assign values to a
>newly inserted row's columns on Oracle 7.3.2 under Solaris 2.5.1 x86.
>
>Let's say the trigger is written the following way:
>
>create trigger triggername
> before insert on tablename
> for each row
>begin
> :new.COLUMNNAME := SOME_VALUE_HERE;
>end;
>
>This trigger would not compile with errors that say something about
>'bad bind variable new'.
>
Received on Wed Apr 22 1998 - 17:22:31 CDT