Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.tools -> Re: CREATING TRIGGER ERROR
I think you are missing 'REFERENCING NEW AS NEW OLD AS OLD' try:
con.execute "CREATE OR REPLACE TRIGGER SYLOGIN.TRI_SEQ_ERRORLOG BEFORE
INSERT ON SYLOGIN.ERRORLOG REFERENCING NEW AS NEW OLD AS OLD FOR EACH ROW
BEGIN SELECT
SYLOGIN.SEQ_ERRORLOG.nextval INTO : new.ID FROM dual; END;"
Have a nice code
JK
"Peta Griffith" <peta_at_dataspeed.com.au> wrote in message
news:hvjp6.9768$v5.39967_at_newsfeeds.bigpond.com...
> Trigger Error
> using the oracle oledb provider and ado with visual basic
> when creating a trigger , this statement will return then error
>
> 'No value given for one or more required parameters'
>
> con.execute "CREATE OR REPLACE TRIGGER SYLOGIN.TRI_SEQ_ERRORLOG BEFORE
> INSERT ON SYLOGIN.ERRORLOG FOR EACH ROW BEGIN SELECT
> SYLOGIN.SEQ_ERRORLOG.nextval INTO : new.ID FROM dual; END;"
>
> this statement will create trigger with no error but the trigger will be
> invalid as there is no colon in the statement
>
> con.execute "CREATE OR REPLACE TRIGGER SYLOGIN.TRI_SEQ_ERRORLOG BEFORE
> INSERT ON SYLOGIN.ERRORLOG FOR EACH ROW BEGIN SELECT
> SYLOGIN.SEQ_ERRORLOG.nextval INTO new.ID FROM dual; END;"
>
>
> help
>
>
Received on Wed Mar 07 2001 - 04:35:31 CST
![]() |
![]() |