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: ORA-06552 while creating a trigger

Re: ORA-06552 while creating a trigger

From: Golan <bcg008_at_mot.com>
Date: 26 Mar 2005 22:34:04 -0800
Message-ID: <35e0ae97.0503262234.525809e6@posting.google.com>


"Arun Mathur" <themathurs_at_gmail.com> wrote in message news:<1111682766.848739.5670_at_o13g2000cwo.googlegroups.com>...
> What version are you running? This worked fine on my development
> instance. See below:
>
> SQL> conn amathur_at_dbdev
> Enter password:
> Connected.
> SQL> select * from v$version;
>
> BANNER
> ----------------------------------------------------------------
> Oracle9i Enterprise Edition Release 9.2.0.1.0 - 64bit Production
> PL/SQL Release 9.2.0.1.0 - Production
> CORE 9.2.0.1.0 Production
> TNS for Solaris: Version 9.2.0.1.0 - Production
> NLSRTL Version 9.2.0.1.0 - Production
>
> SQL> create table test1(a number(3),b timestamp);
>
> Table created.
>
> SQL> create trigger aaa
> 2 before insert on test1
> 3 referencing new as new
> 4 old as old
> 5 for each row
> 6 begin
> 7 null;
> 8 end;
> 9 /
>
> Trigger created.

Thanks Arun.
I've tried it again and I was supprised to find out that it's working. After more investigations I found out that the problem occur when you have a combination of timestamp type field and a timestamp field name ( When I first posted the message, I've changed the names since I didn't think that this is the problem).
For example try:
create table TEST1 (

Event_Timestamp	Timestamp,
Timestamp	Date);

CREATE OR REPLACE TRIGGER AAA
BEFORE INSERT
ON test1
REFERENCING NEW AS NEW OLD AS OLD
FOR EACH ROW
Begin
null;
End;
/

and I guess you'll get the problem.
Anyway, I will change the field name in order to avoid the problem.

Thanks again for your help Received on Sun Mar 27 2005 - 00:34:04 CST

Original text of this message

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