-
ORA-04082: NEW or OLD references not allowed in table level triggers
hi ,
I am getting the following error i am creating the below trigger
create or replace trigger tr_cdc
*
ERROR at line 1:
ORA-04082: NEW or OLD references not allowed in table level triggers
please help.
thanks
create or replace trigger tr_cdc
after insert on cdcsample for each row
begin
insert into cdcsample@dev(a1,a2,a3,a4) values(:new.a1,:new.a2,:new.a3,:new.a4);
end trigger;
-
I am able to create the trigger for an insert to a local table
cdcsample2.
So, it could be the problem for the remote-database.
Did you try to create a procedure that is able to insert a record in cdcsample@dev.
And then call this procedure from the trigger.
Regards
Ben de Boer
-
try
create or replace trigger tr_cdc
after insert on cdcsample for each row
REFERENCING NEW AS NEW OLD AS OLD
begin
insert into cdcsample@dev(a1,a2,a3,a4) values(:new.a1,:new.a2,:new.a3,:new.a4);
end trigger;
Hth
Gregg
-
thank you both of you .
I will try both options and will post
again thanks for the time and help
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|