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

Home -> Community -> Usenet -> c.d.o.server -> Re: Compilation errors in TRIGGER

Re: Compilation errors in TRIGGER

From: Boris Bunjan <bbunjan_at_sunce.hr>
Date: Fri, 30 Jul 1999 10:04:20 +0200
Message-ID: <7nrmff$36n$1@as102.tel.hr>


try this

create trigger trig1 before insert on webtab1 for each row
BEGIN
    select seq1.nextval into :new.id from dual; END;
/

kev wrote in message <37A0530E.32CDD69B_at_fast.no>...
>Hi,
>
>I'm trying to create a trigger for autonumbering. I get this error
>message though:
>
>MGR-00072: Warning: TRIGGER TRIG1 created with compilation errors.
>
>Can I find out what these compilation errors are?
>
>Or even better, can you tell me what's wrong with this code (I'm using
>svrmgrl) ? :-)
>
>create trigger trig1 before insert on webtab1
>for each row
>BEGIN
>:new.id = seq1.nextval;
>END;
>/
>
>seq1 is a sequence. The table webtab1 just has 3 columns: id number(4),
>lname varchar2(10), fname varchar2(10)
>
>Thanks in advance,
>
>- Kev
>
Received on Fri Jul 30 1999 - 03:04:20 CDT

Original text of this message

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