Re: INSERT Trigger
Posted in 1998
Topics: Triggers, Constraints & Referential Integrity
Hi Roland, I'm pretty sure you can't do this with a trigger, as I read in the Informix Docs (I'm using Dynamic Server 7.3 on Windows NT) that a trigger cannot affect it's own table! However, have you thought about a default value on your date column? You change it like this I think: Alter table <tablename> modify ( <date column name> DATE DEFAULT CURRENT NOT NULL); It doesn't have to become NOT NULL (it might already be?) but if you've got a default and it's never updated to NULL then maybe it should be? Pete Bloxam Pete is a Database Administrator in a large UK Software house. Opinions are those of Pete and not of his employer. Roland Pich'r <rpichor@ddc.daewoo.com.pl> wrote in article <35EE465B.CE4B5852@ddc.daewoo.com.pl>... > Hi > > I've got following problem: > > I want to use trigger to set current date in row which I just insert (in > the same table) > > Any ideas how to do this (or just 'no way - it's impossible') ??? > > Thanks, > > Roland Pichor > rpichor@ddc.daewoo.com.pl > > >