db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Yip Ng" <yipng...@gmail.com>
Subject Re: [jira] Commented: (DERBY-1603) ERROR 54038: "Maximum depth of nested triggers was exceeded" occurs when trigger fires after upating 10.1.2.5 jars to 10.1.3.1
Date Mon, 07 Aug 2006 17:20:39 GMT
Another way is to specify which column in the trigger that will invoke the
trigger action.
i.e.:

CREATE TRIGGER update_test
    AFTER UPDATE OF INFO ON test
    REFERENCING OLD AS old
    FOR EACH ROW MODE DB2SQL
    UPDATE test SET timestamp=current_timestamp WHERE testid=old.testid;


On 8/7/06, Kathey Marsden <kmarsdenderby@sbcglobal.net> wrote:
>
> Daniel John Debrunner wrote:
>
> >Then I think this would lead to a simpler action statement of
> >
> >UPDATE TEST SET TIMESTAMP = CURRENT_TIMESTAMP WHERE TESTID = OLD.TESTID
> >
> >A statement trigger might be best in this case, would result in a single
> >update statement rather than N.
> >
> >
> >
> Hmmm....
> Well, this (I think)  is where we started and from what I understand
> from Yip is  the case that is always supposed to give us the "Maximum
> depth of nested triggers was exceeded error" (DERBY-1652).  If the
> trigger is defined this way, when the row is updated, it fires the
> update trigger which updates the row which fires the update
> trigger  etc...
>
> I added the additional qualifier (
>
> > AND INFO != OLD.INFO
>
> to make it stop on the second fire. Is there a better way?
>
> Kathey
>
>
>

Mime
View raw message