Up Prev Next
From: Michael Peppler <mpeppler at peppler dot org>
Subject: Re: Why doesn't error_handler get called if errors occur inside a stored procedure?
Date: Dec 6 2001 1:16AM
Dave Aiello writes:
> We are using Sybase::DBlib and setting message and error handlers using
> &dbmsghandle() and &dberrhandle(). It does not appear that either our message
> handler or our error handler are called if an error occurs inside a stored
> procedure we call via an sql exec statement using DBlib. Why is that?
Actually the message handler should definitely get called. What type
of error are you seeing that doesn't do this?
> Second, would our message and/or error handlers be called if the stored
> procedure contained a raiserror?
A raiserror will also be caught by the message handler, as will also
any PRINT statement in the proc.
Michael Peppler - Data Migrations Inc. - http://www.mbay.net/~mpeppler
email@example.com - firstname.lastname@example.org
International Sybase User Group - http://www.isug.com