Michael Peppler
Sybase Consulting
Sybase on Linux
Install Guide for Sybase on Linux
General Sybase Resources
General Perl Resources
BCP Tool
Bug Tracker
Mailing List Archive
Downloads Directory
Sybase on Linux FAQ
Sybperl FAQ
Michael Peppler's resume

sybperl-l Archive

Up    Prev    Next    

From: Michael Peppler <mpeppler at peppler dot org>
Subject: Re: DBI/DBD::Sybase error handling issues
Date: Apr 24 2002 2:27PM

On Wed, 2002-04-24 at 07:15, Michael Burstin wrote:
> I am once again running into some "interesting" error handling
> sitations.  I have a set of scripts which are actually causing a
> Sybase stacktrace, but in this, I discovered that I am not actually
> catching the Sybase error in my DBI code.  I am in a situation where
> $DBI::errstr is being set, however, $DBI::err is not!  I thought that
> this was an impossible state to get into (I thought they were directly
> tied together, errstr only getting set if err is set).

> Sybase is returning a 5702 error to me (my code is causing a stack
> trace), the Sybase write-up on this states to fix the error causing
> this issue (which I agree), but I don't understand why I don't catch
> this.
> (I know the cause of these errors are someone tried to create a raw
> device on a mounted UFS file system -- these scripts are being
> developed to stage systems, not run on a system once live).

Are you *sure* that the code below causes the 5702 error? Isn't it the
DISK INIT call that would cause the error?

The trace you show is clean - if there is an error from Sybase it
normally gets printed in the trace...

Michael Peppler                              Data Migrations, Inc.           *or*
International Sybase User Group: