Icon View Thread

The following is the text of the current message along with any replies.
Messages 1 to 3 of 3 total
Thread 2nd trigger question
Fri, Apr 17 2009 10:45 AMPermanent Link

"James Relyea"
Will any errors encountered in a trigger be raised to the stored proc that
caused the trigger to fire? Then, can the stored proc raise the exception to
the object that called the stored proc?

Another DB does not raise trigger errors to anything & is an issue I
discovered in another DB; I figured I'd ask before I discovered it myself.

Thanks

Smile
jr

Fri, Apr 17 2009 1:11 PMPermanent Link

Fernando Dias

Team Elevate Team Elevate

James,

> Will any errors encountered in a trigger be raised to the stored proc that
> caused the trigger to fire? Then, can the stored proc raise the exception to
> the object that called the stored proc?

Yes. The stored procedure can raise or "eat" the exception.

--
Fernando Dias
[Team Elevate]

Fri, Apr 17 2009 1:47 PMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

James,

<< Will any errors encountered in a trigger be raised to the stored proc
that caused the trigger to fire? Then, can the stored proc raise the
exception to the object that called the stored proc? >>

Yes.  In fact, unless you specifically catch them in a BEGIN..EXCEPTION
block or an ON ERROR trigger, the exception will always be raised to the
calling procedure and then on to the calling application.

--
Tim Young
Elevate Software
www.elevatesoft.com

Image