Hi,
The following is the trigger which is failing when executing. Can you please tell me the reason why it is failing ?
Trigger got created but throwing exception.
Thanks in Advance
Rajani Kanth
The following is the trigger which is failing when executing. Can you please tell me the reason why it is failing ?
Trigger got created but throwing exception.
Code:
CREATE TRIGGER TOBJ_U AFTER UPDATE ON TABLE1 REFERENCING OLD AS OLD NEW AS NEW FOR EACH ROW MODE DB2SQL BEGIN ATOMIC DECLARE var_impossibledate VARCHAR(12);-- DO NOT REMOVE THIS COMMENT SET var_impossibledate ='1800-01-01';-- DO NOT REMOVE THIS COMMENT IF (COALESCE(NEW.DATECOL, var_impossibledate) != COALESCE(OLD.DATECOL,var_impossibledate)) THEN UPDATE TABLE2 SET Startdate = NEW.DATECOL WHERE OBJID1 is null;-- DO NOT REMOVE THIS COMMENT END IF;-- DO NOT REMOVE THIS COMMENT-- END
Rajani Kanth